Allow inheriting PowerShell installers
This commit is contained in:
parent
4504ca85d4
commit
d9d1575a19
8 changed files with 64 additions and 97 deletions
scripts/Windows/Software
Oh My Posh
PowerShell
aliae
git
vscode
winget
zoxide
|
@ -2,17 +2,8 @@
|
|||
. "$PSScriptRoot/../../../Common/Scripts/Software.ps1";
|
||||
. "$PSScriptRoot/../../../Common/Types/InstallerAction.ps1";
|
||||
|
||||
& {
|
||||
$base = "$PSScriptRoot/../../../Common/Software/Oh My Posh/Manage.ps1";
|
||||
|
||||
Start-SoftwareInstaller @args `
|
||||
-Installer {
|
||||
Install-WingetPackage JanDeDobbeleer.OhMyPosh -ArgumentList "--scope", "machine";
|
||||
} `
|
||||
-Configurator {
|
||||
. $base -Action ([InstallerAction]::Configure) @args;
|
||||
} `
|
||||
-UserConfigurator {
|
||||
. $base -Action ([InstallerAction]::ConfigureUser) @args;
|
||||
};
|
||||
} @args;
|
||||
Start-SoftwareInstaller @args `
|
||||
-Inherit "$PSScriptRoot/../../../Common/Software/Oh My Posh/Manage.ps1" `
|
||||
-Installer {
|
||||
Install-WingetPackage JanDeDobbeleer.OhMyPosh -ArgumentList "--scope", "machine";
|
||||
};
|
||||
|
|
|
@ -1,8 +1,4 @@
|
|||
. "$PSScriptRoot/../../../Common/Scripts/Software.ps1";
|
||||
. "$PSScriptRoot/../../../Common/Types/InstallerAction.ps1";
|
||||
|
||||
Start-SoftwareInstaller @args `
|
||||
-Configurator {
|
||||
. "$PSScriptRoot/../../../Common/Software/PowerShell/Manage.ps1" `
|
||||
-Action ([InstallerAction]::Configure);
|
||||
};
|
||||
Start-SoftwareInstaller @args -Inherit "$PSScriptRoot/../../../Common/Software/PowerShell/Manage.ps1";
|
||||
|
|
|
@ -2,17 +2,8 @@
|
|||
. "$PSScriptRoot/../../../Common/Scripts/Software.ps1";
|
||||
. "$PSScriptRoot/../../../Common/Types/InstallerAction.ps1";
|
||||
|
||||
& {
|
||||
$base = "$PSScriptRoot/../../../Common/Software/aliae/Main.ps1";
|
||||
|
||||
Start-SoftwareInstaller @args `
|
||||
-Installer {
|
||||
Install-WingetPackage JanDeDobbeleer.Aliae -ArgumentList "--scope", "machine";
|
||||
} `
|
||||
-Configurator {
|
||||
. $base -Action ([InstallerAction]::Configure) @args;
|
||||
} `
|
||||
-UserConfigurator {
|
||||
. $base -Action ([InstallerAction]::ConfigureUser) @args;
|
||||
};
|
||||
} @args;
|
||||
Start-SoftwareInstaller @args `
|
||||
-Inherit "$PSScriptRoot/../../../Common/Software/aliae/Main.ps1" `
|
||||
-Installer {
|
||||
Install-WingetPackage JanDeDobbeleer.Aliae -ArgumentList "--scope", "machine";
|
||||
};
|
||||
|
|
|
@ -3,25 +3,15 @@
|
|||
. "$PSScriptRoot/../../../Common/Scripts/Software.ps1";
|
||||
. "$PSScriptRoot/../../../Common/Types/InstallerAction.ps1";
|
||||
|
||||
& {
|
||||
. "$PSScriptRoot/../../../Common/Types/InstallerAction.ps1";
|
||||
$base = "$PSScriptRoot/../../../Common/Software/git/Manage.ps1";
|
||||
Start-SoftwareInstaller @args `
|
||||
-Inherit "$PSScriptRoot/../../../Common/Software/git/Manage.ps1" `
|
||||
-Installer {
|
||||
$params = "/WindowsTerminalProfile";
|
||||
$defaultBranch = Get-OSConfig "git.defaultBranch";
|
||||
|
||||
Start-SoftwareInstaller @args `
|
||||
-Installer {
|
||||
$params = "/WindowsTerminalProfile";
|
||||
$defaultBranch = Get-OSConfig "git.defaultBranch";
|
||||
if ($defaultBranch) {
|
||||
$params += " /DefaultBranchName:`"$defaultBranch`"";
|
||||
}
|
||||
|
||||
if ($defaultBranch) {
|
||||
$params += " /DefaultBranchName:`"$defaultBranch`"";
|
||||
}
|
||||
|
||||
Install-ChocoPackage git -ArgumentList "--params", $params;
|
||||
} `
|
||||
-Configurator {
|
||||
& $base ([InstallerAction]::Configure) @args;
|
||||
} `
|
||||
-UserConfigurator {
|
||||
& $base ([InstallerAction]::ConfigureUser) @args;
|
||||
};
|
||||
} @args;
|
||||
Install-ChocoPackage git -ArgumentList "--params", $params;
|
||||
};
|
||||
|
|
|
@ -1,16 +1,11 @@
|
|||
& {
|
||||
. "$PSScriptRoot/../../Scripts/SoftwareManagement.ps1";
|
||||
. "$PSScriptRoot/../../../Common/Scripts/Software.ps1";
|
||||
. "$PSScriptRoot/../../../Common/Types/InstallerAction.ps1";
|
||||
$base = "$PSScriptRoot/../../../Common/Software/vscode/Main.ps1";
|
||||
. "$PSScriptRoot/../../Scripts/SoftwareManagement.ps1";
|
||||
. "$PSScriptRoot/../../../Common/Scripts/Software.ps1";
|
||||
. "$PSScriptRoot/../../../Common/Types/InstallerAction.ps1";
|
||||
|
||||
Start-SoftwareInstaller @args `
|
||||
-Installer {
|
||||
Install-ChocoPackage vscode -ArgumentList "--params", "/NoDesktopIcon";
|
||||
Install-ChocoPackage vscodium -ArgumentList "--params", "/NoDesktopIcon /AssociateWithFiles";
|
||||
refreshenv;
|
||||
} `
|
||||
-UserConfigurator {
|
||||
& $base ([InstallerAction]::ConfigureUser) @args;
|
||||
};
|
||||
} @args;
|
||||
Start-SoftwareInstaller @args `
|
||||
-Inherit "$PSScriptRoot/../../../Common/Software/vscode/Main.ps1" `
|
||||
-Installer {
|
||||
Install-ChocoPackage vscode -ArgumentList "--params", "/NoDesktopIcon";
|
||||
Install-ChocoPackage vscodium -ArgumentList "--params", "/NoDesktopIcon /AssociateWithFiles";
|
||||
refreshenv;
|
||||
};
|
||||
|
|
|
@ -1,16 +1,14 @@
|
|||
. "$PSScriptRoot/../../../Common/Scripts/Software.ps1";
|
||||
|
||||
& {
|
||||
Start-SoftwareInstaller @args `
|
||||
-Installer {
|
||||
$xamlDownloadLink = "https://github.com/microsoft/microsoft-ui-xaml/releases/download/v2.8.6/Microsoft.UI.Xaml.2.8.x64.appx";
|
||||
$downloadLink = "https://github.com/microsoft/winget-cli/releases/latest/download/Microsoft.DesktopAppInstaller_8wekyb3d8bbwe.msixbundle";
|
||||
$file = New-TemporaryFile;
|
||||
$file = Rename-Item $file "$file.msixbundle" -PassThru;
|
||||
Invoke-WebRequest "$xamlDownloadLink" -OutFile "$file";
|
||||
Add-AppxPackage "$file" -ErrorAction Continue;
|
||||
Invoke-WebRequest "$downloadLink" -OutFile "$file";
|
||||
Add-AppxPackage "$file" -ErrorAction Continue;
|
||||
Remove-Item $file;
|
||||
};
|
||||
} @args;
|
||||
Start-SoftwareInstaller @args `
|
||||
-Installer {
|
||||
$xamlDownloadLink = "https://github.com/microsoft/microsoft-ui-xaml/releases/download/v2.8.6/Microsoft.UI.Xaml.2.8.x64.appx";
|
||||
$downloadLink = "https://github.com/microsoft/winget-cli/releases/latest/download/Microsoft.DesktopAppInstaller_8wekyb3d8bbwe.msixbundle";
|
||||
$file = New-TemporaryFile;
|
||||
$file = Rename-Item $file "$file.msixbundle" -PassThru;
|
||||
Invoke-WebRequest "$xamlDownloadLink" -OutFile "$file";
|
||||
Add-AppxPackage "$file" -ErrorAction Continue;
|
||||
Invoke-WebRequest "$downloadLink" -OutFile "$file";
|
||||
Add-AppxPackage "$file" -ErrorAction Continue;
|
||||
Remove-Item $file;
|
||||
};
|
||||
|
|
|
@ -1,16 +1,11 @@
|
|||
& {
|
||||
. "$PSScriptRoot/../../Scripts/SoftwareManagement.ps1";
|
||||
. "$PSScriptRoot/../../../Common/Scripts/Software.ps1";
|
||||
. "$PSScriptRoot/../../../Common/Software/PowerShell/Profile.ps1";
|
||||
. "$PSScriptRoot/../../../Common/Types/InstallerAction.ps1";
|
||||
$base = "$PSScriptRoot/../../../Common/Software/zoxide/Main.ps1";
|
||||
. "$PSScriptRoot/../../Scripts/SoftwareManagement.ps1";
|
||||
. "$PSScriptRoot/../../../Common/Scripts/Software.ps1";
|
||||
. "$PSScriptRoot/../../../Common/Software/PowerShell/Profile.ps1";
|
||||
. "$PSScriptRoot/../../../Common/Types/InstallerAction.ps1";
|
||||
|
||||
Start-SoftwareInstaller @args `
|
||||
-Installer {
|
||||
Install-ChocoPackage zoxide;
|
||||
Install-WingetPackage junegunn.fzf;
|
||||
} `
|
||||
-Configurator {
|
||||
& $base ([InstallerAction]::Configure) @args;
|
||||
};
|
||||
} @args;
|
||||
Start-SoftwareInstaller @args `
|
||||
-Inherit "$PSScriptRoot/../../../Common/Software/zoxide/Main.ps1" `
|
||||
-Installer {
|
||||
Install-ChocoPackage zoxide;
|
||||
Install-WingetPackage junegunn.fzf;
|
||||
};
|
Loading…
Add table
Add a link
Reference in a new issue