Merge pull request #4410 from shin-/4408-colors-no-tty

Don't strip ANSI color codes when output is not a TTY
This commit is contained in:
Joffrey F 2017-02-01 14:20:10 -08:00 committed by GitHub
commit 67e1111806

View File

@ -33,7 +33,7 @@ def make_color_fn(code):
return lambda s: ansi_color(code, s) return lambda s: ansi_color(code, s)
colorama.init() colorama.init(strip=False)
for (name, code) in get_pairs(): for (name, code) in get_pairs():
globals()[name] = make_color_fn(code) globals()[name] = make_color_fn(code)