File tree Expand file tree Collapse file tree 1 file changed +7
-7
lines changed
Expand file tree Collapse file tree 1 file changed +7
-7
lines changed Original file line number Diff line number Diff line change @@ -365,13 +365,9 @@ function New-ReleasePR {
365365 git push origin $Branch
366366 }
367367
368- $LabelParams = @ {
369- OwnerName = " PowerShell"
370- RepositoryName = $RepositoryName
371- Label = " Ignore"
372- }
368+ $Repo = Get-GitHubRepository - OwnerName PowerShell - RepositoryName $RepositoryName
373369
374- $PRParams = @ {
370+ $Params = @ {
375371 Head = $Branch
376372 Base = " master"
377373 Draft = $true
@@ -381,9 +377,13 @@ function New-ReleasePR {
381377 Confirm = $ConfirmPreference
382378 }
383379
384- $PR = Get-GitHubLabel @LabelParams | New-GitHubPullRequest @PRParams
380+ $PR = $Repo | New-GitHubPullRequest @Params
385381 Write-Host " Draft PR URL: $ ( $PR.html_url ) "
386382
383+ # NOTE: The API is weird. According to GitHub, all PRs are Issues, so this
384+ # works, but the module doesn't support it as easily as it could.
385+ $Repo | Add-GitHubIssueLabel - Issue $PR.PullRequestNumber - LabelName " Ignore"
386+
387387 Pop-Location
388388}
389389
You can’t perform that action at this time.
0 commit comments