Update install.sh

This commit is contained in:
Kroese 2024-05-05 12:01:46 +02:00 committed by GitHub
parent 3913b789bb
commit a37013ffe3
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -50,7 +50,7 @@ startInstall() {
file=$(echo "$file" | sed -e 's/[^A-Za-z0-9._-]/_/g')
fi
ISO="$STORAGE/$file.iso"
! migrateFiles "$ISO" "$VERSION" && error "Migration failed!" && exit 57
@ -65,19 +65,18 @@ startInstall() {
local magic=""
magic=$(dd if="$ISO" seek=0 bs=1 count=1 status=none | tr -d '\000')
magic="$(printf '%s' "$magic" | od -A n -t x1 -v | tr -d ' \n')"
[[ "$magic" == "16" ]] && return 1
if [ -z "$CUSTOM" ]; then
rm -f "$ISO"
else
if [[ "$ISO" != "$CUSTOM_ORG" ]]; then
rm -f "$ISO"
ISO="$CUSTOM_ORG"
CUSTOM="$ISO"
fi
fi
fi
if [ -z "$CUSTOM" ]; then
rm -f "$ISO"
else
if [[ "$ISO" != "$CUSTOM_ORG" ]]; then
rm -f "$ISO"
ISO="$CUSTOM_ORG"
CUSTOM="$ISO"
fi
fi
rm -rf "$TMP"