mirror of
https://github.com/dockur/windows.git
synced 2025-12-19 08:50:37 +00:00
feat: Allow product key configuration (#1110)
This commit is contained in:
@@ -681,6 +681,11 @@ updateXML() {
|
||||
sed -i "s/SERVERSTANDARD<\/Value>/SERVER${EDITION^^}<\/Value>/g" "$asset"
|
||||
fi
|
||||
|
||||
if [ -n "$KEY" ]; then
|
||||
sed -i '/<ProductKey>/,/<\/ProductKey>/d' "$asset"
|
||||
sed -i "s/<\/UserData>/ <ProductKey>\n <Key>${KEY}<\/Key>\n <WillShowUI>OnError<\/WillShowUI>\n <\/ProductKey>\n <\/UserData>/g" "$asset"
|
||||
fi
|
||||
|
||||
return 0
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user