diff options
author | Zac Medico <zmedico@gentoo.org> | 2010-01-29 18:47:51 +0000 |
---|---|---|
committer | Zac Medico <zmedico@gentoo.org> | 2010-01-29 18:47:51 +0000 |
commit | a10c9473d2f46ffa1a98f5a915af09311787a224 (patch) | |
tree | fa2701775e776d48e55ba8d9669ca0a4b70a1ee4 /bin | |
parent | 942c2f3736f4babf7d0ad9c291a8b4252622f13b (diff) | |
download | portage-a10c9473d2f46ffa1a98f5a915af09311787a224.tar.gz portage-a10c9473d2f46ffa1a98f5a915af09311787a224.tar.bz2 portage-a10c9473d2f46ffa1a98f5a915af09311787a224.zip |
Bug #300388 - Fix terminal handling code to so term codes aren't sent when
TERM=dumb. (trunk r15191)
svn path=/main/branches/2.1.7/; revision=15246
Diffstat (limited to 'bin')
-rwxr-xr-x | bin/ebuild | 1 | ||||
-rwxr-xr-x | bin/emaint | 2 | ||||
-rwxr-xr-x | bin/repoman | 1 |
3 files changed, 3 insertions, 1 deletions
diff --git a/bin/ebuild b/bin/ebuild index dc3f448c4..d8eec06a7 100755 --- a/bin/ebuild +++ b/bin/ebuild @@ -88,6 +88,7 @@ if debug and "python-trace" in portage.features: if not opts.color == 'y' and \ (opts.color == 'n' or \ portage.settings.get('NOCOLOR') in ('yes', 'true') or \ + portage.settings.get('TERM') == 'dumb' or \ not sys.stdout.isatty()): portage.output.nocolor() portage.settings.unlock() diff --git a/bin/emaint b/bin/emaint index 9da3f4220..90301dbff 100755 --- a/bin/emaint +++ b/bin/emaint @@ -536,7 +536,7 @@ def emaint_main(myargv): status = "Attempting to fix %s" func = "fix" - isatty = sys.stdout.isatty() + isatty = os.environ.get('TERM') != 'dumb' and sys.stdout.isatty() for task in tasks: print(status % task.name()) inst = task() diff --git a/bin/repoman b/bin/repoman index 7778447d5..ec6f2d41e 100755 --- a/bin/repoman +++ b/bin/repoman @@ -96,6 +96,7 @@ repoman_settings = portage.config(local_config=False, repoman_settings.lock() if repoman_settings.get("NOCOLOR", "").lower() in ("yes", "true") or \ + repoman_settings.get('TERM') == 'dumb' or \ not sys.stdout.isatty(): nocolor() |