Refactor Windows setup scripts
This commit is contained in:
parent
182727eb8d
commit
c5a401f7eb
2 changed files with 101 additions and 97 deletions
scripts/Windows/OS
|
@ -39,12 +39,12 @@ $newCommand.SelectSingleNode("./ua:CommandLine", $namespace).InnerText = `
|
|||
$(Get-Content "$PSScriptRoot/InitialBoot.ps1") + `
|
||||
"; pwsh '$([System.IO.Path]::GetRelativePath("$PSScriptRoot/../../..", $env:SETUP_SCRIPT_NAME))';";
|
||||
|
||||
$order = [int]$newCommand.SelectSingleNode("./ua:Order", $namespace).InnerText;
|
||||
$newCommand.SelectSingleNode("./ua:Order", $namespace).InnerText = $order + 1;
|
||||
$orderElement = $newCommand.SelectSingleNode("./ua:Order", $namespace);
|
||||
$orderElement.InnerText = ([int]($orderElement.InnerText) + 1);
|
||||
$newCommand.SelectSingleNode("./ua:Description", $namespace).InnerText = "Install PowerShell Core and git and run setup script";
|
||||
|
||||
if ($Global:SetupConfigPostprocessor) {
|
||||
$Global:SetupConfigPostprocessor.Invoke($unattendedConfig, $namespace);
|
||||
if (Get-Command Initialize-SetupConfig) {
|
||||
Initialize-SetupConfig $unattendedConfig $namespace;
|
||||
}
|
||||
|
||||
$unattendedConfig.PreserveWhitespace = $true;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue