show-{merged,unmerged}-branches will ignore any branch name containing the default branch name
Nobody has claimed this yet.
- Dominant language
- Shell
- Stars
- 18.1k
- Forks
- 1.2k
- Avg merge
- 5d 17h
- Merged PRs (30d)
- 1
Description
The show-merged-branches and show-unmerged-branches scripts both pipe their output through a series of greps which include:
| grep -v "$(git_extra_default_branch)"
...Which will exclude any branch with a name that contains the default branch name, not merely matches it. For example, in this set of branches:
$ git branch --merged
a-branch
+ an-other
+ main
mainly-merged-code
+ remaining-work
returned-to-main
If the default branch name is main, all of the last four branches would be hidden from a git show-merged-branches listing, not only main itself:
$ git show-merged-branches
a-branch
+an-other
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with the show-merged-branches and show-unmerged-branches scripts and inspect the grep pipeline around git_extra_default_branch. Reproduce the example with branches containing and exactly matching the default branch name, then verify both listings retain containing names while excluding only the exact default branch.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- git, shell
- Domain
- cli
- Issue type
- Bug
- Difficulty
- 2/5
- Estimated time
- 1-3 hours
- Activity status
- Active
- Clarity
- Clearly specified
- Newbie friendliness
- 86/100