Closed zuhanit closed 2 years ago
Using colorama as dependency would be simplest way to color terminal text: https://github.com/tartley/colorama
ANSI escape character sequences have long been used to produce colored terminal text and cursor positioning on Unix and Macs. Colorama makes this work on Windows, too, by wrapping stdout, stripping ANSI sequences it finds (which would appear as gobbledygook in the output), and converting them into the appropriate win32 calls to modify the state of the terminal. On other platforms, Colorama does nothing.
Sounds good to me, thanks for the PR!
This changes
RuntimeError
messages to print looks like actual codes. See #54examples:
Duplicate Section
Duplicate Key