Update define.sh

This commit is contained in:
Kroese 2024-05-26 05:34:39 +02:00 committed by GitHub
parent 83b35f6fa0
commit bd4ba9620d
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -2111,6 +2111,7 @@ prepareXP() {
echo "\"DefaultSettings.YResolution\"=dword:00000438"
echo ""
echo "[HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\RunOnceEx]"
echo "\"Script\"=\"cmd /C if exist \\\"C:\OEM\install.bat\\\" start \\\"Install\\\" \\\"cmd /C C:\OEM\install.bat\\\"\""
echo "\"ScreenSaver\"=\"reg add \\\"HKCU\\\\Control Panel\\\\Desktop\\\" /f /v \\\"SCRNSAVE.EXE\\\" /t REG_SZ /d \\\"off\\\"\""
echo "\"ScreenSaverOff\"=\"reg add \\\"HKCU\\\\Control Panel\\\\Desktop\\\" /f /v \\\"ScreenSaveActive\\\" /t REG_SZ /d \\\"0\\\"\""
echo ""
@ -2124,6 +2125,12 @@ prepareXP() {
echo ""
} | unix2dos > "$dir/\$OEM\$/admin.vbs"
{ echo "[COMMANDS]"
echo "\"REGEDIT /s install.reg\""
echo "\"Wscript admin.vbs\""
echo ""
} | unix2dos > "$dir/\$OEM\$/cmdlines.txt"
local oem=""
local folder="/oem"
@ -2144,21 +2151,10 @@ prepareXP() {
fi
file=$(find "$folder" -maxdepth 1 -type f -iname install.bat | head -n 1)
if [ -f "$file" ]; then
unix2dos -q "$file"
oem="start cmd /C C:\OEM\install.bat"
fi
[ -f "$file" ]&& unix2dos -q "$file"
fi
{ echo "[COMMANDS]"
echo "\"REGEDIT /s install.reg\""
echo "\"Wscript admin.vbs\""
echo "\"$oem\""
echo ""
} | unix2dos > "$dir/\$OEM\$/cmdlines.txt"
return 0
}