feat: Dynamic architecture

This commit is contained in:
Kroese 2024-04-24 14:50:55 +02:00 committed by GitHub
parent 49f27c9939
commit c316d876c1
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -27,6 +27,7 @@ if [ -z "$CUSTOM" ] && [[ "${VERSION,,}" != "http"* ]]; then
fi
ESD_URL=""
ARCH="ARM64"
TMP="$STORAGE/tmp"
DIR="$TMP/unpack"
FB="falling back to manual installation!"
@ -213,14 +214,13 @@ getESD() {
local dir="$1"
local file="$2"
local architecture="ARM64"
local winCatalog size
case "${VERSION,,}" in
win11arm64)
"win11${ARCH,,}")
winCatalog="https://go.microsoft.com/fwlink?linkid=2156292"
;;
win10arm64)
"win10${ARCH,,}")
winCatalog="https://go.microsoft.com/fwlink/?LinkId=841361"
;;
*)
@ -254,7 +254,7 @@ getESD() {
local esdLang="en-us"
local editionName="Professional"
local edQuery='//File[Architecture="'${architecture}'"][Edition="'${editionName}'"]'
local edQuery='//File[Architecture="'${ARCH}'"][Edition="'${editionName}'"]'
echo -e '<Catalog>' > "${dir}/products_filter.xml"
xmllint --nonet --xpath "${edQuery}" "${dir}/products.xml" >> "${dir}/products_filter.xml" 2>/dev/null
@ -391,10 +391,10 @@ extractESD() {
local edition imageIndex imageEdition
case "${VERSION,,}" in
win11arm64)
"win11${ARCH,,}")
edition="11 pro"
;;
win10arm64)
"win10${ARCH,,}")
edition="10 pro"
;;
*)