Suggestion:
- I found out that
GRUB_HIDDEN_TIMEOUT=X is very confusing
and
GRUB_HIDDEN_TIMEOUT_QUIET=true is useless as it make no sense to show a countdown without the menu
- My I suggest the replacement of commands
GRUB_HIDDEN_TIMEOUT=X and
GRUB_HIDDEN_TIMEOUT_QUIET=true
GRUB_TIMEOUT="X"
As an example:
With: 00_header:
.
.
.
if [ -s /boot/grub/grubenv ]; then
have_grubenv=true
load_env
fi
set default="${GRUB_DEFAULT}" set hidemenu="${GRUB_HIDE_MENU}"
if [ \${prev_saved_entry} ]; then
saved_entry=\${prev_saved_entry}
save_env saved_entry
prev_saved_entry=
save_env prev_saved_entry
fi
.
.
.
if [ \${recordfail} = 1 ]; then set timeout=${FAULT_TIMEOUT} set hidemenu=false
else set timeout=${DEFAULT_TIMEOUT}
fi
if [ \${timeout} = -1 ]; then set hidemenu=false fi
As you can see in this example:
If recordfail=0 (normal BOOT)
- timeout will be = DEFAULT_TIMEOUT
- menu isn't displayed If GRUB_HIDE_MENU="true" and DEFAULT_TIMEOUT=NOT(-1)
If recordfail=1 (BOOT after BOOT fail)
- timeout will be = FAULT_TIMEOUT
- menu is displayed regardless of GRUB_HIDE_MENU="true"