From 9d00952bdf91152f789422e2a9086d5139a8ff8d Mon Sep 17 00:00:00 2001 From: Olafur Egilsson Date: Fri, 22 Jan 2021 07:35:43 +0000 Subject: [PATCH] Use the value from toolset visualStudio.edition when locating VSIXInstaller (#2476) * Use the value from toolset visualStudio.edition when locating VSIXInstaller. Previously it was hardwired to "Enterprise". * Changed as per review: https://github.com/actions/virtual-environments/pull/2476#discussion_r559966129 --- images/win/scripts/ImageHelpers/InstallHelpers.ps1 | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/images/win/scripts/ImageHelpers/InstallHelpers.ps1 b/images/win/scripts/ImageHelpers/InstallHelpers.ps1 index 8498ac33f..225b99ffb 100644 --- a/images/win/scripts/ImageHelpers/InstallHelpers.ps1 +++ b/images/win/scripts/ImageHelpers/InstallHelpers.ps1 @@ -220,12 +220,13 @@ function Install-VsixExtension $argumentList = ('/quiet', "`"$FilePath`"") Write-Host "Starting Install $Name..." + $vsEdition = (Get-ToolsetContent).visualStudio.edition try { #There are 2 types of packages at the moment - exe and vsix if ($Name -match "vsix") { - $process = Start-Process -FilePath "C:\Program Files (x86)\Microsoft Visual Studio\$VSversion\Enterprise\Common7\IDE\VSIXInstaller.exe" -ArgumentList $argumentList -Wait -PassThru + $process = Start-Process -FilePath "C:\Program Files (x86)\Microsoft Visual Studio\$VSversion\${vsEdition}\Common7\IDE\VSIXInstaller.exe" -ArgumentList $argumentList -Wait -PassThru } else {