mirror of
https://github.com/dockur/windows.git
synced 2025-10-29 12:15:50 +00:00
Update install.sh
This commit is contained in:
parent
d4c173988a
commit
347a9151f3
1 changed files with 13 additions and 7 deletions
|
|
@ -536,15 +536,21 @@ extractESD() {
|
||||||
|
|
||||||
local edition imageIndex imageEdition
|
local edition imageIndex imageEdition
|
||||||
|
|
||||||
case "${version,,}" in
|
edition=$(printVersion "$version" "")
|
||||||
"win11${PLATFORM,,}" ) edition="11 pro" ;;
|
edition="${edition/ (Evaluation)/}"
|
||||||
"win10${PLATFORM,,}" ) edition="10 pro" ;;
|
|
||||||
*) error "Invalid VERSION specified, value \"$version\" is not recognized!" && return 1 ;;
|
if [ -z "$edition" ] || ! isESD "${version,,}"; then
|
||||||
esac
|
error "Invalid VERSION specified, value \"$version\" is not recognized!" && return 1
|
||||||
|
fi
|
||||||
|
|
||||||
for (( imageIndex=4; imageIndex<=esdImageCount; imageIndex++ )); do
|
for (( imageIndex=4; imageIndex<=esdImageCount; imageIndex++ )); do
|
||||||
imageEdition=$(wimlib-imagex info "${iso}" ${imageIndex} | grep '^Description:' | sed 's/Description:[ \t]*//')
|
imageEdition=$(wimlib-imagex info "${iso}" ${imageIndex} | grep '^Description:' | sed 's/Description:[ \t]*//')
|
||||||
[[ "${imageEdition,,}" != *"$edition"* ]] && continue
|
error "$imageEdition"
|
||||||
|
done
|
||||||
|
|
||||||
|
for (( imageIndex=4; imageIndex<=esdImageCount; imageIndex++ )); do
|
||||||
|
imageEdition=$(wimlib-imagex info "${iso}" ${imageIndex} | grep '^Description:' | sed 's/Description:[ \t]*//')
|
||||||
|
[[ "${imageEdition,,}" != *"${edition,,}"* ]] && continue
|
||||||
wimlib-imagex export "${iso}" ${imageIndex} "${installWimFile}" --compress=LZMS --chunk-size 128K --quiet || {
|
wimlib-imagex export "${iso}" ${imageIndex} "${installWimFile}" --compress=LZMS --chunk-size 128K --quiet || {
|
||||||
retVal=$?
|
retVal=$?
|
||||||
error "Addition of ${imageIndex} to the $desc image failed" && return $retVal
|
error "Addition of ${imageIndex} to the $desc image failed" && return $retVal
|
||||||
|
|
@ -552,7 +558,7 @@ extractESD() {
|
||||||
return 0
|
return 0
|
||||||
done
|
done
|
||||||
|
|
||||||
error "Failed to find product in install.wim!" && return 1
|
error "Failed to find product '$edition' in install.wim!" && return 1
|
||||||
}
|
}
|
||||||
|
|
||||||
extractImage() {
|
extractImage() {
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue