From fcaea6e9ae5cb12e934dbc2185810c29f2218ccd Mon Sep 17 00:00:00 2001 From: Patrick Schleizer Date: Wed, 25 Oct 2023 12:40:03 -0400 Subject: [PATCH] adjust stages executing for new error handling method --- grml-debootstrap | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-) diff --git a/grml-debootstrap b/grml-debootstrap index 17a8b1c..d00dc0c 100755 --- a/grml-debootstrap +++ b/grml-debootstrap @@ -2151,12 +2151,9 @@ for i in format_efi_partition prepare_vm mkfs tunefs \ preparechroot execute_pre_scripts chrootscript execute_post_scripts \ remove_configs umount_chroot grub_install umount_target fscktool ; do if stage "${i}" ; then - "$i" - if [ $? -eq 0 ]; then - stage "${i}" 'done' && rm -f "${STAGES}/${i}" - else - bailout 2 "$i" - fi + "$i" || bailout 2 "$i" + stage "${i}" 'done' + rm -f "${STAGES}/${i}" fi done -- 2.1.4