From 66b82f139f7938feabb6852dab24001a6303f3e7 Mon Sep 17 00:00:00 2001 From: Kroese Date: Sat, 27 Apr 2024 11:57:17 +0200 Subject: [PATCH] fix: Support read-only images --- src/power.sh | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/power.sh b/src/power.sh index cc28f8d..aebb0a2 100644 --- a/src/power.sh +++ b/src/power.sh @@ -68,8 +68,9 @@ finish() { if [ ! -f "$STORAGE/windows.boot" ] && [ -f "$STORAGE/$BASE" ]; then # Remove CD-ROM ISO after install if ready; then - rm -f "$STORAGE/$BASE" - touch "$STORAGE/windows.boot" + if rm -f "$STORAGE/$BASE" 2>/dev/null; then + touch "$STORAGE/windows.boot" + fi fi fi