From 5b1424647801d51b321de7f83c798bad1493b1bb Mon Sep 17 00:00:00 2001 From: Kroese Date: Wed, 13 Nov 2024 00:21:13 +0100 Subject: [PATCH] feat: Support committing to image --- src/reset.sh | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/reset.sh b/src/reset.sh index e11d8e4..6476efd 100644 --- a/src/reset.sh +++ b/src/reset.sh @@ -17,6 +17,7 @@ echo "❯ For support visit $SUPPORT" : "${BOOT:=""}" # URL of the ISO file : "${DEBUG:="N"}" # Disable debugging +: "${COMMIT:="N"}" # Commit to image : "${MACHINE:="virt"}" # Machine selection : "${ALLOCATE:=""}" # Preallocate diskspace : "${ARGUMENTS:=""}" # Extra QEMU parameters @@ -80,6 +81,8 @@ fi # Check folder +[[ "$COMMIT" != [Nn]* ]] && STORAGE="/local" + if [ ! -d "$STORAGE" ]; then error "Storage folder ($STORAGE) not found!" && exit 13 fi