I'd like to see that script.
git log --author=rav --numstat --no-merges --pretty=format: |
awk -e '{ a += $1; b += $2; } END { print a; print b; print a-b; }'
produces this output (sum additions, sum deletions, net line additions): 112529
85383
27146 git log --numstat --no-merges --pretty=format:%an
| awk '
author == "" { author = $0; next }
/^$/ { author = ""; next }
{ added[author] += $1; removed[author] += $2 }
END { for (author in added) {
print author, "added", added[author], "removed", removed[author], "sum", added[author]-removed[author]
} }'
| sort -n -k 7It wasn't really all that tricky though, it took me a few hours to write. git-log has options for only displaying the status line of diff-stat for each commit, and then displaying the parents of each commit, and the author. You look to see that there's only one parent (so it's not a merge), parse out the X added, Y deleted numbers, and stick them in a dictionary keyed by name.
A lot of the script was just getting statistics like average/min/max/stddev line counts, and printing them nicely.