Last Updated: February 25, 2016
·
233
· marcin-wosinek

Merge commits since creating the branch

git branch --remote | # get all branches
awk '{print "echo " $0 " `git merge-base" $0 " origin/master`"}' | # commands to produce "<branch name> <common ancesstor>"
xargs -0 bash -c | # execute commands
awk '{print "echo " $1 " - `git log --pretty=oneline " $2 "..." $1 " --merges | wc -l`"}' | # commands to count merges between
xargs -0 bash -c # execute commands