mirror of
https://github.com/sphinx-doc/sphinx.git
synced 2026-10-13 17:02:12 -05:00
Don't color output if stdout is not a tty.
This commit is contained in:
1 parent
ca78ec11e9
commit
8f842f5ace
1 file changed
+1
-1
+1
-1
@@ -99,7 +99,7 @@ def main(argv):
|
||||
elif opt == '-N':
|
||||
nocolor()
|
||||
|
||||
if sys.platform == 'win32':
|
||||
if not sys.stdout.isatty() or sys.platform == 'win32':
|
||||
# Windows' cmd box doesn't understand ANSI sequences
|
||||
nocolor()
|
||||
|
||||
|
||||
Reference in new issue
Block a user