[Merge] ~xnox/grub:fix-postinst-empty-devices into ~ubuntu-core-dev/grub/+git/ubuntu:ubuntu
Michael Vogt
michael.vogt at canonical.com
Wed Sep 30 12:57:12 UTC 2020
Still approving (but added some ideas) - I tested the fix on the affected machine and it works as expected.
Diff comments:
> diff --git a/debian/grub-multi-install b/debian/grub-multi-install
> index 9bd4089..bedc700 100755
> --- a/debian/grub-multi-install
> +++ b/debian/grub-multi-install
> @@ -402,7 +402,14 @@ while :; do
> db_fset grub-efi/install_devices_empty seen false
> fi
> else
> - exit 1 # noninteractive
> + # if question was seen we are done
> + # Otherwise, abort
> + db_fget grub-efi/install_devices_empty seen
> + if [ "$RET" = true ]; then
> + break
> + else
> + exit 1
Fwiw, I would change this to "exit 31" or anything but 1. Bonus points for some messages on stderr.
> + fi
> fi
> else
> break
> diff --git a/debian/postinst.in b/debian/postinst.in
> index e6dfe36..cedc137 100644
> --- a/debian/postinst.in
> +++ b/debian/postinst.in
> @@ -685,7 +685,14 @@ case "$1" in
> db_fset grub-pc/install_devices_empty seen false
> fi
> else
> - exit 1 # noninteractive
> + # if question was seen we are done
> + # Otherwise, abort
> + db_fget grub-pc/install_devices_empty seen
> + if [ "$RET" = true ]; then
> + break
> + else
> + exit 1
Same as above but I would pick a different exit code from above to make it easier to find in bugreport where the exit happend.
> + fi
> fi
> else
> break
--
https://code.launchpad.net/~xnox/grub/+git/grub/+merge/391438
Your team Ubuntu Core Development Team is requested to review the proposed merge of ~xnox/grub:fix-postinst-empty-devices into ~ubuntu-core-dev/grub/+git/ubuntu:ubuntu.
More information about the Ubuntu-reviews
mailing list