mirror of
https://github.com/dockur/windows.git
synced 2026-08-04 04:57:13 +01:00
feat: Added support for Reactos (#1999)
This commit is contained in:
+20
-2
@@ -510,7 +510,7 @@ skipVersion() {
|
||||
local id="$1"
|
||||
|
||||
case "${id,,}" in
|
||||
"win9"* | "winxp"* | "win2k"* | "win2003"* )
|
||||
"win9"* | "winxp"* | "win2k"* | "win2003"* | "reactos" )
|
||||
return 0 ;;
|
||||
esac
|
||||
|
||||
@@ -624,6 +624,24 @@ detectLegacy() {
|
||||
return 1
|
||||
}
|
||||
|
||||
detectReactOS() {
|
||||
|
||||
local dir="$1"
|
||||
local marker
|
||||
|
||||
marker=$(find "$dir" -maxdepth 2 -type f \
|
||||
\( \
|
||||
-ipath '*/reactos/reactos.inf' -o \
|
||||
-ipath '*/reactos/unattend.inf' \
|
||||
\) \
|
||||
-print -quit) || return 1
|
||||
|
||||
[ -n "$marker" ] || return 1
|
||||
|
||||
DETECTED="reactos"
|
||||
return 0
|
||||
}
|
||||
|
||||
resolveImage() {
|
||||
|
||||
local version="$1"
|
||||
@@ -821,7 +839,7 @@ detectImage() {
|
||||
|
||||
info "Detecting version from ISO image..."
|
||||
|
||||
if detectLegacy "$dir"; then
|
||||
if detectLegacy "$dir" || detectReactOS "$dir"; then
|
||||
desc=$(printEdition "$DETECTED" "$DETECTED" "Y") || return 1
|
||||
info "Detected: $desc"
|
||||
return 0
|
||||
|
||||
Reference in New Issue
Block a user