Skip to content

Instantly share code, notes, and snippets.

@jakobjs
Created February 11, 2020 14:39
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save jakobjs/b1acaab17f1d5432f7c3e1488de2a6fd to your computer and use it in GitHub Desktop.
Save jakobjs/b1acaab17f1d5432f7c3e1488de2a6fd to your computer and use it in GitHub Desktop.
vs_install.ps1
Import-Module "$env:ChocolateyInstall\helpers\chocolateyInstaller.psm1" -Force
$layoutPath = "C:\VisualStudio2019_ENT\layout"
$packageName = "Arion_Visual_Studio_2019_16.4.4"
#$selectedWorkloads = "--add Microsoft.VisualStudio.Workload.ManagedDesktop --add Microsoft.VisualStudio.Workload.NativeDesktop --add Microsoft.VisualStudio.Workload.NetCoreTools --add Microsoft.VisualStudio.Workload.Node --add Microsoft.VisualStudio.Component.VC.v141.MFC"
$selectedWorkloads = "--allWorkloads"
$packageArgs = @{
packageName = $packageName
fileType = 'EXE'
file = $(Join-Path $layoutPath "vs_Professional.exe")
softwareName = 'Microsoft Visual Studio 2019 Professional'
silentArgs = "$setupPrefix --passive --norestart --wait --nocache --noUpdateInstaller --noWeb $selectedWorkloads --includeOptional --includeRecommended --locale En-us"
validExitCodes = @(0, 3010, 1641)
}
Install-ChocolateyInstallPackage @packageArgs
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment