aboutsummaryrefslogtreecommitdiffstats
path: root/lib/bb/msg.py
diff options
context:
space:
mode:
Diffstat (limited to 'lib/bb/msg.py')
-rw-r--r--lib/bb/msg.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/bb/msg.py b/lib/bb/msg.py
index 93575d89c..3e18596fa 100644
--- a/lib/bb/msg.py
+++ b/lib/bb/msg.py
@@ -230,7 +230,7 @@ def logger_create(name, output=sys.stderr, level=logging.INFO, preserve_handlers
console = logging.StreamHandler(output)
console.addFilter(bb.msg.LogFilterShowOnce())
format = bb.msg.BBLogFormatter("%(levelname)s: %(message)s")
- if color == 'always' or (color == 'auto' and output.isatty()):
+ if color == 'always' or (color == 'auto' and output.isatty() and os.environ.get('NO_COLOR', '') == ''):
format.enable_color()
console.setFormatter(format)
if preserve_handlers: