Modify PRs as Issues #333
Labels
enhancement
An issue or pull request introducing new functionality to the project.
triage needed
An issue that needs to be reviewed by a member of the team.
Feature Idea Summary
Hello,
According to the GitHub API Documentation
Take, for example, adding a Label to a PR. This module currently has no direct cmdlet to do so, that is, there's no
Add-GitHubPRLabel
. There is, of course,Add-GitHubIssueLabel
. This cmdlet works with PRs, but only in a hacky way (take thePullRequestNumber
field of aPullRequest
object and supply it toAdd-GitHubIssueLabel
as the value for the-Issue
parameter. Instead, all Issue cmdlets in this module should support PRs: that is, a PR object when pipelined to an Issue cmdlet should be treated just like an issue.Feature Idea Additional Details
Here's the current hacky way to add a label to a PR (and please correct me if I'm wrong!), assuming
$Repo
is a Repo object and@Params
is an adequate set of params forNew-GitHubPullRequest
:When instead it should just be:
I imagine based on my cusory browsing of the module's implementation that we could add some filter that turns a PR object into an Issue object, and then modify every Issue cmdlet to do that for PRs, or something to that effect.
Requested Assignment
Operating System
PowerShell Version
Module Version
The text was updated successfully, but these errors were encountered: