On Mon, Aug 10, 2009 at 05:10:31PM +0200, Robert Millan wrote:
> On Mon, Aug 10, 2009 at 12:55:05PM +0100, Colin Watson wrote:
> > > If we default to verbose, we could also have an option to turn it off from
> > > /etc/default/grub, if that makes life easier for you.
> > 
> > Slightly, I suppose. I thought there were some feelings against
> > excessive numbers of options which is why I didn't suggest that.
> > GRUB_HIDDEN_TIMEOUT_QUIET=1?
> 
> For this one I don't mind.  But would you please make it "(true|false)" ?

OK. How's this?

Thanks,

-- 
Colin Watson                                       [[email protected]]
diff -Nur -x '*.orig' -x '*~' grub2-1.96+20090725/util/grub-mkconfig.in grub2-1.96+20090725.new/util/grub-mkconfig.in
--- grub2-1.96+20090725/util/grub-mkconfig.in	2009-08-08 19:31:00.000000000 +0100
+++ grub2-1.96+20090725.new/util/grub-mkconfig.in	2009-08-13 09:39:20.000000000 +0100
@@ -173,7 +173,7 @@
 export GRUB_DEVICE GRUB_DEVICE_UUID GRUB_DEVICE_BOOT GRUB_DEVICE_BOOT_UUID GRUB_FS GRUB_FONT_PATH GRUB_PRELOAD_MODULES
 
 # These are optional, user-defined variables.
-export GRUB_DEFAULT GRUB_TIMEOUT GRUB_DISTRIBUTOR GRUB_CMDLINE_LINUX GRUB_CMDLINE_LINUX_DEFAULT GRUB_TERMINAL_INPUT GRUB_TERMINAL_OUTPUT GRUB_SERIAL_COMMAND GRUB_DISABLE_LINUX_UUID GRUB_DISABLE_LINUX_RECOVERY GRUB_GFXMODE
+export GRUB_DEFAULT GRUB_HIDDEN_TIMEOUT GRUB_HIDDEN_TIMEOUT_QUIET GRUB_TIMEOUT GRUB_DISTRIBUTOR GRUB_CMDLINE_LINUX GRUB_CMDLINE_LINUX_DEFAULT GRUB_TERMINAL_INPUT GRUB_TERMINAL_OUTPUT GRUB_SERIAL_COMMAND GRUB_DISABLE_LINUX_UUID GRUB_DISABLE_LINUX_RECOVERY GRUB_GFXMODE
 
 if test "x${grub_cfg}" != "x"; then
   rm -f ${grub_cfg}.new
diff -Nur -x '*.orig' -x '*~' grub2-1.96+20090725/util/grub.d/00_header.in grub2-1.96+20090725.new/util/grub.d/00_header.in
--- grub2-1.96+20090725/util/grub.d/00_header.in	2009-08-13 09:32:50.000000000 +0100
+++ grub2-1.96+20090725.new/util/grub.d/00_header.in	2009-08-13 09:39:20.000000000 +0100
@@ -37,7 +37,6 @@
 
 cat << EOF
 set default=${GRUB_DEFAULT}
-set timeout=${GRUB_TIMEOUT}
 EOF
 
 case ${GRUB_TERMINAL_INPUT}:${GRUB_TERMINAL_OUTPUT} in
@@ -112,3 +111,20 @@
 EOF
   ;;
 esac
+
+if [ "x${GRUB_HIDDEN_TIMEOUT}" != "x" ] ; then
+  if [ "x${GRUB_HIDDEN_TIMEOUT_QUIET}" = "xtrue" ] ; then 
+    verbose=
+  else
+    verbose=" --verbose"
+  fi
+  cat << EOF
+if sleep$verbose --interruptible ${GRUB_HIDDEN_TIMEOUT} ; then
+  set timeout=${GRUB_TIMEOUT}
+fi
+EOF
+else
+  cat << EOF
+set timeout=${GRUB_TIMEOUT}
+EOF
+fi
_______________________________________________
Grub-devel mailing list
[email protected]
http://lists.gnu.org/mailman/listinfo/grub-devel

Reply via email to