aboutsummaryrefslogtreecommitdiffstats
path: root/meta/recipes-core/initrdscripts/files/init-install-efi.sh
diff options
context:
space:
mode:
Diffstat (limited to 'meta/recipes-core/initrdscripts/files/init-install-efi.sh')
-rw-r--r--meta/recipes-core/initrdscripts/files/init-install-efi.sh22
1 files changed, 14 insertions, 8 deletions
diff --git a/meta/recipes-core/initrdscripts/files/init-install-efi.sh b/meta/recipes-core/initrdscripts/files/init-install-efi.sh
index d58826a240..f564f4e2d6 100644
--- a/meta/recipes-core/initrdscripts/files/init-install-efi.sh
+++ b/meta/recipes-core/initrdscripts/files/init-install-efi.sh
@@ -78,17 +78,23 @@ for hdname in $hdnamelist; do
cat /sys/block/$hdname/device/uevent
fi
echo
- # Get user choice
- while true; do
- echo -n "Do you want to install this image there? [y/n] "
- read answer
- if [ "$answer" = "y" -o "$answer" = "n" ]; then
+done
+
+# Get user choice
+while true; do
+ echo "Please select an install target or press n to exit ($hdnamelist ): "
+ read answer
+ if [ "$answer" = "n" ]; then
+ echo "Installation manually aborted."
+ exit 1
+ fi
+ for hdname in $hdnamelist; do
+ if [ "$answer" = "$hdname" ]; then
+ TARGET_DEVICE_NAME=$answer
break
fi
- echo "Please answer y or n"
done
- if [ "$answer" = "y" ]; then
- TARGET_DEVICE_NAME=$hdname
+ if [ -n "$TARGET_DEVICE_NAME" ]; then
break
fi
done