Skip to content

Instantly share code, notes, and snippets.

@aaronparker
Last active November 11, 2023 23:47
Show Gist options
  • Save aaronparker/f223693aa5ad143dc8aa8fc07c4a7c28 to your computer and use it in GitHub Desktop.
Save aaronparker/f223693aa5ad143dc8aa8fc07c4a7c28 to your computer and use it in GitHub Desktop.
Install Windows Terminal on Windows Server
Install-Module -Name "Evergreen"
$Path = "C:\Temp\Terminal"
New-Item -Path $Path -ItemType "Directory"
$App = @{
Version = "2.8.6"
URI = "https://globalcdn.nuget.org/packages/microsoft.ui.xaml.2.8.6.nupkg"
}
$OutFile = Save-EvergreenApp -InputObject $App -LiteralPath $Path
Rename-Item -Path $OutFile.FullName -NewName "microsoft.ui.xaml.zip"
$ZipFile = Get-ChildItem -Path $Path -Recurse -Include "microsoft.ui.xaml.zip"
Expand-Archive -Path $ZipFile.FullName -DestinationPath $Path
$XamlAppxFile = Get-ChildItem -Path "$Path\tools\AppX\x64\Release" -Recurse -Include "Microsoft.UI.Xaml.*.appx"
DISM.EXE /Online /Add-ProvisionedAppxPackage /PackagePath:$($XamlAppxFile.FullName) /SkipLicense
$App = @{
Version = "14.00"
URI = "https://aka.ms/Microsoft.VCLibs.x64.14.00.Desktop.appx"
}
$OutFile = Save-EvergreenApp -InputObject $App -LiteralPath $Path
DISM.EXE /Online /Add-ProvisionedAppxPackage /PackagePath:$($OutFile.FullName) /SkipLicense
$OutFile = Get-EvergreenApp -Name "MicrosoftTerminal" | Save-EvergreenApp -LiteralPath $Path
DISM.EXE /Online /Add-ProvisionedAppxPackage /PackagePath:$($OutFile.FullName) /SkipLicense
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment