From bf61184217619819201d6a7c14b94a8454e71717 Mon Sep 17 00:00:00 2001 From: Ollo Date: Sat, 4 Mar 2023 19:20:41 +0100 Subject: [PATCH] Stop download on failure during generation --- tools/initialDietFlash.sh | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/tools/initialDietFlash.sh b/tools/initialDietFlash.sh index 41fc7a5..16319f6 100755 --- a/tools/initialDietFlash.sh +++ b/tools/initialDietFlash.sh @@ -48,6 +48,10 @@ if [ "$FILES" != "config.lua" ]; then echo "Compress $f ..." out=$(echo "$f" | sed 's/.lua/_diet.lua/g') $DIET ../$f -o ../diet/$out + if [ $? -ne 0 ]; then + echo "Failed to generate file" + exit $? + fi OUTFILES="$OUTFILES diet/$out" else OUTFILES="$OUTFILES $f"