I'm working on a GitHub repo with lots of branches and pull requests.
Let's say, for example, that I have the following pull requests:
a
to branch X
b
to branch X
c
to branch Y
d
to branch X
e
to branch Y
.Is there a way to find all the pull requests that are targeted for branch X
(i.e. a -> X
, b -> X
, d -> X
)?
Filter pull requests that someone has asked you directly to review: state:open type:pr user-review-requested:@me. Filter pull requests by the team requested for review: state:open type:pr team-review-requested:github/atom. Filter for pull requests that are linked to an issue that the pull request may close: linked: ...
There can be only one open PR from a given branch.
Open TerminalTerminalGit Bash. Fetch the reference to the pull request based on its ID number, creating a new branch in the process. At this point, you can do anything you want with this branch. You can run some local tests, or merge other branches into the branch.
Yes, you can do it.
In Github's terminology the "to branch" is "base" So the search phrase is: is:open is:pr base:X
Official description: Search based on branch names
Optionally you can add is:merged
or is:unmerged
filters as well.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With