Skip GRUB config if user supplies empty response

This commit is contained in:
Salt 2020-12-04 06:39:11 -06:00
parent 6d63d415fd
commit c6ffd94ee7

View File

@ -320,6 +320,10 @@ build-gentoo-chroot() {
build-bootloader() {
# Last few chroot steps, mostly involving GRUB
read -p "Enter device to install GRUB to: " grubdev
if [ -z "$grubdev" ]; then
log "Skipping"
return 0
fi
log "Configuring GRUB"
[ -f /boot/grub ] && rm /boot/grub -f
[ -d /boot/grub ] || mkdir /boot/grub -p