From 002badce44a073058ff636914e48e4ae58ae10c1 Mon Sep 17 00:00:00 2001 From: Thomas Nagy Date: Sun, 17 Aug 2014 22:59:18 +0200 Subject: [PATCH] new command-line option --color - Issue 1474 --- waflib/Logs.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/waflib/Logs.py b/waflib/Logs.py index 77b2e43f..00ea9deb 100644 --- a/waflib/Logs.py +++ b/waflib/Logs.py @@ -179,7 +179,8 @@ class formatter(logging.Formatter): except Exception: msg = rec.msg - if rec.stream.isatty(): + use = colors_lst['USE'] + if (use == 1 and rec.stream.isatty()) or use == 2: c1 = getattr(rec, 'c1', None) if c1 is None: