Skip to content

Instantly share code, notes, and snippets.

View willhyper's full-sized avatar

Chao-Wei Chen willhyper

View GitHub Profile
@tibbon
tibbon / gist:2569089
Created May 1, 2012 15:56
Git Repo Statistics commands
git log --shortstat | grep "files changed" | awk '{files+=$1; inserted+=$4; deleted+=$6} END {print "files changed", files, "lines inserted:", inserted, "lines deleted:", deleted}'
git log --shortstat --author "David Fisher" | grep "files changed" | awk '{files+=$1; inserted+=$4; deleted+=$6} END {print "files changed", files, "lines inserted:", inserted, "lines deleted:", deleted}'
git log --pretty=format:%an | awk '{ ++c[$0]; } END { for(cc in c) printf "%5d %s\n",c[cc],cc; }'| sort -r
git shortlog -sn --no-merges
git log --graph --full-history --all --color \
--pretty=format:"%x1b[31m%h%x09%x1b[32m%d%x1b[0m%x20%s"