Created
September 16, 2011 15:14
-
-
Save nikreiman/1222337 to your computer and use it in GitHub Desktop.
Function to view all git commits for a given branch
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function git-log-for-branch() { | |
branch="$1" | |
git --no-pager log --format=online --no-merges $branch --not \ | |
$(git for-each-ref --format="%(refname)" refs/remotes/origin | \ | |
grep -F -v $branch) | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment