mirror of
https://github.com/linuxboot/heads.git
synced 2025-02-07 11:30:11 +00:00
Show the last setting for a config option if more than one exist
This commit is contained in:
parent
ab0f9dd32e
commit
43a858e25c
@ -67,7 +67,7 @@ while true; do
|
|||||||
exit 0
|
exit 0
|
||||||
;;
|
;;
|
||||||
"b" )
|
"b" )
|
||||||
CURRENT_OPTION=`grep 'CONFIG_BOOT_DEV=' /tmp/config | cut -f2 -d '=' | tr -d '"'`
|
CURRENT_OPTION=`grep 'CONFIG_BOOT_DEV=' /tmp/config | tail -n1 | cut -f2 -d '=' | tr -d '"'`
|
||||||
find /dev -name 'sd*' -o -name 'nvme*' > /tmp/filelist.txt
|
find /dev -name 'sd*' -o -name 'nvme*' > /tmp/filelist.txt
|
||||||
file_selector "/tmp/filelist.txt" "Choose the default /boot device.\n\nCurrently set to $CURRENT_OPTION."
|
file_selector "/tmp/filelist.txt" "Choose the default /boot device.\n\nCurrently set to $CURRENT_OPTION."
|
||||||
if [ "$FILE" == "" ]; then
|
if [ "$FILE" == "" ]; then
|
||||||
@ -94,7 +94,7 @@ while true; do
|
|||||||
sleep 5
|
sleep 5
|
||||||
fi
|
fi
|
||||||
|
|
||||||
CURRENT_OPTION=`grep 'CONFIG_USB_BOOT_DEV=' /tmp/config | cut -f2 -d '=' | tr -d '"'`
|
CURRENT_OPTION=`grep 'CONFIG_USB_BOOT_DEV=' /tmp/config | tail -n1 | cut -f2 -d '=' | tr -d '"'`
|
||||||
find /dev -name 'sd*' -o -name 'nvme*' > /tmp/filelist.txt
|
find /dev -name 'sd*' -o -name 'nvme*' > /tmp/filelist.txt
|
||||||
file_selector "/tmp/filelist.txt" "Choose the default USB boot device.\n\nCurrently set to $CURRENT_OPTION."
|
file_selector "/tmp/filelist.txt" "Choose the default USB boot device.\n\nCurrently set to $CURRENT_OPTION."
|
||||||
if [ "$FILE" == "" ]; then
|
if [ "$FILE" == "" ]; then
|
||||||
|
Loading…
x
Reference in New Issue
Block a user