Added patch from Martin Parm <parmus@diku.dk> to fix the --no-color option. This...
authorChris Gianelloni <wolf31o2@gentoo.org>
Thu, 8 Feb 2007 00:08:29 +0000 (00:08 +0000)
committerChris Gianelloni <wolf31o2@gentoo.org>
Thu, 8 Feb 2007 00:08:29 +0000 (00:08 +0000)
git-svn-id: svn+ssh://svn.gentoo.org/var/svnroot/genkernel/trunk@480 67a159dc-881f-0410-a524-ba9dfbe2cb84

ChangeLog
gen_cmdline.sh
gen_funcs.sh

index b521e290b63b1966af31f2e02c9c151f12111f1c..e855a98688a1b620cba4448cc21072d348d671a3 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -2,6 +2,11 @@
 # Copyright 2006-2007 Gentoo Foundation; Distributed under the GPL v2
 # $Header: $
 
+  08 Feb 2007; Chris Gianelloni <wolf31o2@gentoo.org> gen_cmdline.sh,
+  gen_funcs.sh:
+  Added patch from Martin Parm <parmus@diku.dk> to fix the --no-color option.
+  This resolves bug #114156.
+
   15 Jan 2007; Chris Gianelloni <wolf31o2@gentoo.org> gen_bootloader.sh:
   Changed basename to dirname when creating the directory from grub.conf to
   solve bug #161716.
index bd61f6ff51a164824e1d4cbd432fa5deeb6125ba..2561890fa3bcbc49a26c06b9e687be722909f406 100755 (executable)
@@ -417,12 +417,14 @@ parse_cmdline() {
                      print_info 2 "CMD_ARCHOVERRIDE: $CMD_ARCHOVERRIDE"
              ;;
              --color)
-                     CMD_USECOLOR=1
-                     print_info 2 "CMD_USECOLOR: $CMD_USECOLOR"
+                     USECOLOR=1
+                     print_info 2 "USECOLOR: $USECOLOR"
+                     setColorVars
              ;;
              --no-color)
-                     CMD_USECOLOR=0
-                     print_info 2 "CMD_USECOLOR: $CMD_USECOLOR"
+                     USECOLOR=0
+                     print_info 2 "USECOLOR: $USECOLOR"
+                     setColorVars
              ;;
              --debugfile=*)
                      CMD_DEBUGFILE=`parse_opt "$*"`
index d419e0d386d29cc9ba639a65a5e3990a52061c8c..e0245abfb353fe43ff0758d25c675724fb2ad7e2 100755 (executable)
@@ -21,6 +21,7 @@ isTrue() {
        return 1
 }
 
+setColorVars() { 
 if isTrue ${USECOLOR}
 then
        GOOD=$'\e[32;01m'
@@ -37,6 +38,8 @@ else
        BOLD=''
        UNDER=''
 fi
+}
+setColorVars
 
 dump_debugcache() {
        TODEBUGCACHE=0