diff --git a/etc/functions b/etc/functions index 9df019f..58f2579 100644 --- a/etc/functions +++ b/etc/functions @@ -7,7 +7,10 @@ err() { header() { if [ "$DEBUG" == "1" ]; then echo please enter enter - read + read a + if [ "$a" == "2" ]; then + set -x + fi fi clear echo "#### $1" diff --git a/main.sh b/main.sh index ed71621..582507f 100755 --- a/main.sh +++ b/main.sh @@ -10,12 +10,11 @@ tmp_target="${main}/tmp_target" vars="${target}/tmp/vinstaller/vars" files="./files" -if [ "${DEBUG}" == "1" ]; then - umount -R ${target}/boot/efi ${target}/boot ${target}/tmp/vinstaller/ ${target}/home ${target} - vgchange -an - cryptsetup close /dev/mapper/luks* - rm -rf $main -fi +umount -R ${target}/boot/efi ${target}/boot ${target}/tmp/vinstaller/ ${target}/home ${target} +vgchange -an +cryptsetup close /dev/mapper/luks* +rm -rf $main + if [ "${DEBUG}" == "2" ]; then set -x fi