Update install.sh

This commit is contained in:
Kroese 2024-04-29 17:06:49 +02:00 committed by GitHub
parent e930211622
commit cbaec17250
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -345,21 +345,26 @@ downloadImage() {
desc=$(printVersion "$version" "Windows for ${PLATFORM}") desc=$(printVersion "$version" "Windows for ${PLATFORM}")
fi fi
if isMido "$version"; then if [[ "${PLATFORM,,}" == "x64" ]]; then
tried="y" if isMido "$version"; then
doMido "$iso" "$version" "$desc" && return 0 tried="y"
doMido "$iso" "$version" "$desc" && return 0
fi
fi fi
if isESD "$version"; then if isESD "$version"; then
[[ "$tried" != "n" ]] && info "Failed to download $desc using Mido, will try a different method now..." if [[ "${PLATFORM,,}" == "x64" ]]; then
ISO="$TMP/$version.esd" [[ "$tried" != "n" ]] && info "Failed to download $desc using Mido, will try a different method now..."
iso="$ISO"
ISO="$TMP/$version.esd"
iso="$ISO"
rm -rf "$TMP"
mkdir -p "$TMP"
fi
tried="y" tried="y"
rm -rf "$TMP"
mkdir -p "$TMP"
if getESD "$TMP/esd" "$version"; then if getESD "$TMP/esd" "$version"; then
downloadFile "$iso" "$ESD_URL" "$desc" && return 0 downloadFile "$iso" "$ESD_URL" "$desc" && return 0