From: Michael Prokop Date: Tue, 24 Jan 2017 20:33:53 +0000 (+0100) Subject: Honor GRUB_DISABLE_LINUX_UUID=true for all Debian releases X-Git-Tag: v0.77~1 X-Git-Url: https://git.grml.org/?p=grml-debootstrap.git;a=commitdiff_plain;h=900df89874f060271a621a5937ab8030df403419;hp=b22ae359003c6ce1d91138ffb54279d3f2963ba5 Honor GRUB_DISABLE_LINUX_UUID=true for all Debian releases There's no point in having a release specific check when checking configuration setting for GRUB_DISABLE_LINUX_UUID. So if GRUB_DISABLE_LINUX_UUID is set to "true" then always honor it. Thanks: hex2a for the initial patch (see PR #96) Closes grml/grml-debootstrap#87 --- diff --git a/grml-debootstrap b/grml-debootstrap index b158645..61dab37 100755 --- a/grml-debootstrap +++ b/grml-debootstrap @@ -1288,17 +1288,13 @@ fi ;; esac - case "$RELEASE" in - lenny|squeeze|wheezy) - if grep -q '^GRUB_DISABLE_LINUX_UUID=.*true' "${MNTPOINT}"/etc/default/grub 2>/dev/null ; then - ewarn "GRUB_DISABLE_LINUX_UUID is set to true in /etc/default/grub, not adjusting root= in grub.cfg." - ewarn "Please note that your system might NOT be able to properly boot." - else - einfo "Adjusting grub.cfg for successful boot sequence." - sed -i "s;root=[^ ]\+;root=UUID=$TARGET_UUID;" "${MNTPOINT}"/boot/grub/grub.cfg - fi - ;; - esac + if grep -q '^GRUB_DISABLE_LINUX_UUID=.*true' "${MNTPOINT}"/etc/default/grub 2>/dev/null ; then + ewarn "GRUB_DISABLE_LINUX_UUID is set to true in /etc/default/grub, not adjusting root= in grub.cfg." + ewarn "Please note that your system might NOT be able to properly boot." + else + einfo "Adjusting grub.cfg for successful boot sequence." + sed -i "s;root=[^ ]\+;root=UUID=$TARGET_UUID;" "${MNTPOINT}"/boot/grub/grub.cfg + fi umount "${MNTPOINT}"/proc umount "${MNTPOINT}"/sys