mirror of
https://github.com/actions/runner-images-sangeeth.git
synced 2025-12-20 06:29:50 +00:00
validate set for new functions
This commit is contained in:
@@ -69,6 +69,7 @@ function Get-VisualStudioInstallation {
|
|||||||
Param
|
Param
|
||||||
(
|
(
|
||||||
[Parameter(Mandatory)]
|
[Parameter(Mandatory)]
|
||||||
|
[ValidateSet('VS','BuildTools')]
|
||||||
[String] $VSInstallType
|
[String] $VSInstallType
|
||||||
)
|
)
|
||||||
|
|
||||||
@@ -92,6 +93,7 @@ function Get-VisualStudioComponents {
|
|||||||
Param
|
Param
|
||||||
(
|
(
|
||||||
[Parameter(Mandatory)]
|
[Parameter(Mandatory)]
|
||||||
|
[ValidateSet('VS','BuildTools')]
|
||||||
[String] $VSInstallType
|
[String] $VSInstallType
|
||||||
)
|
)
|
||||||
(Get-VisualStudioInstallation -VSInstallType $VSInstallType).Packages | Where-Object type -in 'Component', 'Workload' |
|
(Get-VisualStudioInstallation -VSInstallType $VSInstallType).Packages | Where-Object type -in 'Component', 'Workload' |
|
||||||
|
|||||||
Reference in New Issue
Block a user