2024-08-08 02:36:35 +00:00
|
|
|
using namespace System.Security.AccessControl;
|
|
|
|
using namespace System.Security.Principal;
|
|
|
|
|
|
|
|
param(
|
|
|
|
$Action,
|
|
|
|
[hashtable] $Arguments
|
|
|
|
)
|
|
|
|
|
2024-08-09 13:56:16 +00:00
|
|
|
. "$PSScriptRoot/../../Scripts/Security.ps1";
|
2024-08-08 02:36:35 +00:00
|
|
|
. "$PSScriptRoot/../../../Common/Scripts/Software.ps1";
|
2024-08-08 12:09:20 +00:00
|
|
|
. "$PSScriptRoot/../../../Common/Types/InstallerAction.ps1";
|
2024-08-08 02:36:35 +00:00
|
|
|
|
|
|
|
Start-SoftwareInstaller @PSBoundParameters `
|
|
|
|
-Installer {
|
2024-08-08 12:09:20 +00:00
|
|
|
param(
|
|
|
|
[scriptblock] $Installer
|
|
|
|
)
|
|
|
|
|
2024-08-08 02:36:35 +00:00
|
|
|
$env:NVS_HOME = "$env:ProgramData\nvs";
|
|
|
|
git clone "https://github.com/jasongin/nvs.git" $env:NVS_HOME;
|
|
|
|
& "$env:NVS_HOME\nvs.cmd" install;
|
|
|
|
|
|
|
|
refreshenv;
|
2024-08-09 13:56:16 +00:00
|
|
|
Set-UserPermissions $env:NVS_HOME;
|
2024-08-08 12:09:20 +00:00
|
|
|
& $Installer -Action ([InstallerAction]::Configure);
|
2024-08-08 02:36:35 +00:00
|
|
|
} `
|
|
|
|
-Configurator {
|
|
|
|
nvs add latest;
|
|
|
|
nvs link latest;
|
|
|
|
};
|