Skip to content

Instantly share code, notes, and snippets.

@iangreenleaf
Created April 21, 2011 23:58
Show Gist options
  • Save iangreenleaf/935741 to your computer and use it in GitHub Desktop.
Save iangreenleaf/935741 to your computer and use it in GitHub Desktop.
Git interrogation oneliners
# Cumulative totals of lines added/deleted
git log --numstat STARTING_HASH..ENDING_HASH -M | grep '^[0-9]\+[[:space:]]\+[0-9]\+[[:space:]]' | awk '{added+=$1} {deleted+=$2} END { print added, deleted }'
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment