mirror of
https://github.com/microsoft/terminal.git
synced 2025-12-10 18:43:54 -06:00
tools: add support for the -Prerelease VS locations (#1202)
take advantage of the switch parameter on the Cmdlet Get-VSSetupInstance from the vssetup module.
This commit is contained in:
parent
1580c1e093
commit
e60af3ba76
@ -51,7 +51,9 @@ function Import-LocalModule
|
||||
function Set-MsbuildDevEnvironment
|
||||
{
|
||||
[CmdletBinding()]
|
||||
param()
|
||||
param(
|
||||
[switch]$Prerelease
|
||||
)
|
||||
|
||||
$ErrorActionPreference = 'Stop'
|
||||
|
||||
@ -59,7 +61,7 @@ function Set-MsbuildDevEnvironment
|
||||
|
||||
Write-Verbose 'Searching for VC++ instances'
|
||||
$vsinfo = `
|
||||
Get-VSSetupInstance -All `
|
||||
Get-VSSetupInstance -All -Prerelease:$Prerelease `
|
||||
| Select-VSSetupInstance `
|
||||
-Latest -Product * `
|
||||
-Require 'Microsoft.VisualStudio.Component.VC.Tools.x86.x64'
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user