git branch -a --contains <hash>
gives me all those branches containing hash
. what I want is git branch -a --no-contains <hash>
. Unfortunately, there doesn't seem to be a command to accomplish this, so I'm thinking the solution is something like:
git branch -a | grep -v output of(git branch -a --contains)
but my bash isn't up to the task.
Show all branches that commit A is on and commit B is not on? would seem to apply, but the approach seems more complicated than necessary.
What is the best/most simple approach to accomplish the above?
The --no-contains
flag was added in Git 2.13.
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