Created
January 25, 2022 11:19
-
-
Save michaelkc/8fe69a0a8ad7d1de80f8c7a59f0b2607 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$vsWhere = "${env:ProgramFiles(x86)}\Microsoft Visual Studio\Installer\vswhere.exe" | |
$vsInstallerShell = "${env:ProgramFiles(x86)}\Microsoft Visual Studio\Installer\vs_installershell.exe" | |
$vsInstallPath = &$vsWhere -format json|convertfrom-json|select -expand installationPath | |
foreach ($installPath in $vsInstallPath) | |
{ | |
$argumentList = "update --passive --norestart --force --installpath `"$installPath`"" | |
Start-Process -FilePath $vsInstallerShell -ArgumentList $argumentList -wait | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment