Making 'git branch --contains' less tedious
Find yourself repeatedly using:
bash
git branch --contains [commit-hash]
in order to track changesets?
Here's a handy function you can include in your .bash_profile to save your keystrokes:
function gbc() { git branch --contains $1; }
Now you can simply call
bash
gbc [commit-hash]
and get your results.
Sometimes it's the simple things in life that matter!
Written by Daniel Beattie
Related protips
Have a fresh tip? Share with Coderwall community!
Post
Post a tip
Sponsored by #native_company# — Learn More
#native_title#
#native_desc#