@@ -16,7 +16,6 @@ function Update-Branch {
16
16
[CmdletBinding (SupportsShouldProcess )]
17
17
param (
18
18
[Parameter (Mandatory )]
19
- [ValidateSet ([RepoNames ])]
20
19
[string ]$RepositoryName
21
20
)
22
21
Use-Repository - RepositoryName $RepositoryName - Script {
@@ -37,7 +36,6 @@ function Get-Bullets {
37
36
[CmdletBinding ()]
38
37
param (
39
38
[Parameter (Mandatory )]
40
- [ValidateSet ([RepoNames ])]
41
39
[string ]$RepositoryName ,
42
40
43
41
[Parameter (Mandatory , ValueFromPipeline )]
@@ -97,7 +95,7 @@ function Get-Bullets {
97
95
98
96
# NOTE: The URL matcher must be explicit because the body of a PR may
99
97
# contain other URLs with digits (like an image asset).
100
- $IssueRegex = ' (' + ($CloseKeywords -join ' |' ) + ' )\s+((https://github.com/PowerShell/(?<repo>(' + ([ RepoNames ]::Values -join ' | ' ) + ' ))/issues/)|#)(?<number>\d+)'
98
+ $IssueRegex = ' (' + ($CloseKeywords -join ' |' ) + ' )\s+((https://github.com/PowerShell/(?<repo>(vscode-powershell|PowerShellEditorServices ))/issues/)|#)(?<number>\d+)'
101
99
}
102
100
103
101
process {
@@ -112,7 +110,7 @@ function Get-Bullets {
112
110
$number = $Matches.number
113
111
$repo = $Matches.repo
114
112
# Handle links to issues in both repos, in both shortcode and URLs.
115
- $name = [ RepoNames ]::Values | Where-Object { $repo -match $_ } | Select-Object - First 1
113
+ $name = ( " vscode-powershell " , " PowerShellEditorServices " ) | Where-Object { $repo -match $_ } | Select-Object - First 1
116
114
" $ ( $name ?? $RepositoryName ) #$number "
117
115
} else {
118
116
" $RepositoryName #$ ( $_.number ) "
@@ -141,7 +139,7 @@ function Update-Changelog {
141
139
[CmdletBinding (SupportsShouldProcess )]
142
140
param (
143
141
[Parameter (Mandatory )]
144
- [ValidateSet ([ RepoNames ] )]
142
+ [ValidateSet (" vscode-powershell " , " PowerShellEditorServices " )]
145
143
[string ]$RepositoryName ,
146
144
147
145
[Parameter (Mandatory )]
@@ -228,7 +226,7 @@ function Update-Version {
228
226
[CmdletBinding (SupportsShouldProcess )]
229
227
param (
230
228
[Parameter (Mandatory )]
231
- [ValidateSet ([ RepoNames ] )]
229
+ [ValidateSet (" vscode-powershell " , " PowerShellEditorServices " )]
232
230
[string ]$RepositoryName
233
231
)
234
232
$Version = Get-Version - RepositoryName $RepositoryName
@@ -287,7 +285,7 @@ function New-ReleasePR {
287
285
[CmdletBinding (SupportsShouldProcess )]
288
286
param (
289
287
[Parameter (Mandatory )]
290
- [ValidateSet ([ RepoNames ] )]
288
+ [ValidateSet (" vscode-powershell " , " PowerShellEditorServices " )]
291
289
[string ]$RepositoryName
292
290
)
293
291
$Version = Get-Version - RepositoryName $RepositoryName
@@ -340,11 +338,10 @@ function New-Release {
340
338
[CmdletBinding (SupportsShouldProcess )]
341
339
param (
342
340
[Parameter (Mandatory )]
343
- [ValidateSet ([ RepoNames ] )]
341
+ [ValidateSet (" vscode-powershell " , " PowerShellEditorServices " )]
344
342
[string ]$RepositoryName ,
345
343
346
344
[Parameter (Mandatory )]
347
- [ValidateScript ({ $_.StartsWith (" v" ) })]
348
345
[string ]$Version
349
346
)
350
347
# TODO: Automate rolling a preview to a stable release.
@@ -363,11 +360,9 @@ function New-ReleaseBundle {
363
360
[CmdletBinding (SupportsShouldProcess )]
364
361
param (
365
362
[Parameter (Mandatory )]
366
- [ValidateScript ({ $_.StartsWith (" v" ) })]
367
363
[string ]$PsesVersion ,
368
364
369
365
[Parameter (Mandatory )]
370
- [ValidateScript ({ $_.StartsWith (" v" ) })]
371
366
[string ]$VsceVersion
372
367
)
373
368
" PowerShellEditorServices" , " vscode-powershell" | ForEach-Object {
@@ -391,7 +386,6 @@ function New-DraftRelease {
391
386
[CmdletBinding (SupportsShouldProcess )]
392
387
param (
393
388
[Parameter (Mandatory )]
394
- [ValidateSet ([RepoNames ])]
395
389
[string ]$RepositoryName ,
396
390
397
391
[Parameter ()]
0 commit comments