Reorder installation steps
This commit is contained in:
parent
ae3b877c2a
commit
a0deb0b84b
1 changed files with 19 additions and 19 deletions
|
@ -68,17 +68,30 @@ $null = New-Module {
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (-not (Test-Winget)) {
|
||||||
|
. "$PSScriptRoot/../Software/winget/Manage.ps1";
|
||||||
|
continue;
|
||||||
|
}
|
||||||
|
|
||||||
|
if (-not (& { wsl --status; $?; })) {
|
||||||
|
wsl --install --no-launch;
|
||||||
|
Restart-Intermediate;
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
if (-not (wsl --shell-type login type -t nix)) {
|
||||||
|
ubuntu install --root;
|
||||||
|
wsl -- sh `<`(curl -L https://nixos.org/nix/install`) --daemon --yes;
|
||||||
|
wsl --shutdown;
|
||||||
|
continue;
|
||||||
|
}
|
||||||
|
|
||||||
Invoke-Hook "Install-PSModules" -Fallback {
|
Invoke-Hook "Install-PSModules" -Fallback {
|
||||||
Install-Module -AcceptLicense -Force PSWindowsUpdate;
|
Install-Module -AcceptLicense -Force PSWindowsUpdate;
|
||||||
Install-Module -AcceptLicense -Force PSScriptAnalyzer;
|
Install-Module -AcceptLicense -Force PSScriptAnalyzer;
|
||||||
. "$PSScriptRoot/../../Common/Software/PinnedItem/Manage.ps1";
|
. "$PSScriptRoot/../../Common/Software/PinnedItem/Manage.ps1";
|
||||||
};
|
};
|
||||||
|
|
||||||
if (-not (Test-Winget)) {
|
|
||||||
. "$PSScriptRoot/../Software/winget/Manage.ps1";
|
|
||||||
continue;
|
|
||||||
}
|
|
||||||
|
|
||||||
if (-not (Test-PSPackage Selenium.WebDriver)) {
|
if (-not (Test-PSPackage Selenium.WebDriver)) {
|
||||||
Install-Module -AcceptLicense -Force NuGet;
|
Install-Module -AcceptLicense -Force NuGet;
|
||||||
Import-Module NuGet;
|
Import-Module NuGet;
|
||||||
|
@ -87,20 +100,7 @@ $null = New-Module {
|
||||||
}
|
}
|
||||||
|
|
||||||
Install-ChocoPackage selenium-gecko-driver firefox;
|
Install-ChocoPackage selenium-gecko-driver firefox;
|
||||||
|
|
||||||
if (-not (& { wsl --status; $?; })) {
|
|
||||||
wsl --install --no-launch;
|
|
||||||
Restart-Intermediate;
|
|
||||||
return;
|
|
||||||
} else {
|
|
||||||
ubuntu install --root;
|
|
||||||
wsl -- sh `<`(curl -L https://nixos.org/nix/install`) --daemon --yes;
|
|
||||||
wsl --shutdown;
|
|
||||||
}
|
|
||||||
|
|
||||||
if (wsl --shell-type login type -t nix) {
|
|
||||||
Set-Stage ([SetupStage]::Configure);
|
Set-Stage ([SetupStage]::Configure);
|
||||||
}
|
|
||||||
} else {
|
} else {
|
||||||
$null = Import-Module PSWindowsUpdate;
|
$null = Import-Module PSWindowsUpdate;
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue