summaryrefslogtreecommitdiff
path: root/trunk/src
diff options
context:
space:
mode:
authorfuzzyray <fuzzyray@gentoo.org>2005-09-22 21:50:06 +0000
committerfuzzyray <fuzzyray@gentoo.org>2005-09-22 21:50:06 +0000
commit9f14ffaace0061891d7a1e74348c747a94e68885 (patch)
tree482a52ef40292a7e517c19313072d8a1c9895640 /trunk/src
parentd90c021148887561925717113e0da6bb2aa429a9 (diff)
downloadgentoolkit-9f14ffaace0061891d7a1e74348c747a94e68885.tar.gz
Fix NOCOLOR to always be honored Bug #98634, enabled no-pipe option
svn path=/; revision=240
Diffstat (limited to 'trunk/src')
-rwxr-xr-xtrunk/src/equery/equery8
1 files changed, 3 insertions, 5 deletions
diff --git a/trunk/src/equery/equery b/trunk/src/equery/equery
index 23ca6e3..69b6d76 100755
--- a/trunk/src/equery/equery
+++ b/trunk/src/equery/equery
@@ -1517,10 +1517,7 @@ def configure():
# Guess colour output
if (Config["color"] == -1 and \
- ((not sys.stdout.isatty()) or \
- (gentoolkit.settings["NOCOLOR"] in ["yes","true"]))) \
- or \
- Config["color"] == 0:
+ ((not sys.stdout.isatty()) or (gentoolkit.settings["NOCOLOR"] in ["yes","true"]))):
pp.output.nocolor()
# Guess piping output
@@ -1557,6 +1554,7 @@ def parseArgs(args):
sys.exit(0)
elif x in ["-C", "--nocolor"]:
Config["color"] = 0
+ pp.output.nocolor()
elif x in ["-N", "--no-pipe"]:
Config["piping"] = False
elif x in ["-q","--quiet"]:
@@ -1575,8 +1573,8 @@ def parseArgs(args):
return (command, local_opts)
if __name__ == "__main__":
- (cmd, local_opts) = parseArgs(sys.argv[1:])
configure()
+ (cmd, local_opts) = parseArgs(sys.argv[1:])
if cmd:
try:
cmd.perform(local_opts)