From e88b38c685a955e91c2aed213cccb52dceb90659 Mon Sep 17 00:00:00 2001 From: Ing Date: Fri, 29 Mar 2024 05:21:28 +0800 Subject: [PATCH] fix rebootto --- files/initrd/opt/rr/include/functions.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/files/initrd/opt/rr/include/functions.sh b/files/initrd/opt/rr/include/functions.sh index b9e01bc2..21382b7d 100755 --- a/files/initrd/opt/rr/include/functions.sh +++ b/files/initrd/opt/rr/include/functions.sh @@ -332,7 +332,7 @@ function getLogo() { function rebootTo() { MODES="config recovery junior" [ -z "${1}" ] && exit 1 - if ! echo "${MODES}" | grep -q "${1}"; then exit 1; fi + if ! echo "${MODES}" | grep -qw "${1}"; then exit 1; fi # echo "Rebooting to ${1} mode" GRUBPATH="$(dirname $(find ${PART1_PATH}/ -name grub.cfg 2>/dev/null | head -1))" ENVFILE="${GRUBPATH}/grubenv"