Skip to content

Commit 1a2e280

Browse files
[release/9.0] Support using MSBuild from xcopy msbuild tool package though VS installation exists (#15972)
Co-authored-by: Gang Wang <[email protected]>
1 parent 13b2084 commit 1a2e280

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

eng/common/tools.ps1

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -416,7 +416,7 @@ function InitializeVisualStudioMSBuild([bool]$install, [object]$vsRequirements =
416416

417417
# Locate Visual Studio installation or download x-copy msbuild.
418418
$vsInfo = LocateVisualStudio $vsRequirements
419-
if ($vsInfo -ne $null) {
419+
if ($vsInfo -ne $null -and $env:ForceUseXCopyMSBuild -eq $null) {
420420
# Ensure vsInstallDir has a trailing slash
421421
$vsInstallDir = Join-Path $vsInfo.installationPath "\"
422422
$vsMajorVersion = $vsInfo.installationVersion.Split('.')[0]

0 commit comments

Comments
 (0)