tests/util/grub-shell: Allow setting the value of debug regardless of its previous state

This allows an invocation of grub-shell to set the value of debug regardless
of the global default environment variable GRUB_SHELL_DEFAULT_DEBUG.

Signed-off-by: Glenn Washburn <development@efficientek.com>
Reviewed-by: Daniel Kiper <daniel.kiper@oracle.com>
This commit is contained in:
Glenn Washburn 2023-07-10 22:01:18 -05:00 committed by Daniel Kiper
parent 76e8962e85
commit e1b97d7c37

View File

@ -248,6 +248,8 @@ for option in "$@"; do
trim=0 ;;
--debug)
debug=$((debug+1)) ;;
--debug=*)
debug=$((`echo "$option" | sed -e 's/--debug=//'`)) ;;
--modules=*)
ms=`echo "$option" | sed -e 's/--modules=//' -e 's/,/ /g'`
modules="$modules $ms" ;;