Created
April 27, 2016 20:57
-
-
Save creative-quant/34126ab9fbcb4e1921b753302966b542 to your computer and use it in GitHub Desktop.
a script to get git user and project stats
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
#!/bin/bash | |
echo "by $USER" | |
git log --shortstat --author "$USER" \ | |
| grep "files\? changed" \ | |
| awk '{files+=$1; inserted+=$4; deleted+=$6} END \ | |
{print "files changed", files, "lines inserted:", inserted, "lines deleted:", deleted}' | |
echo "total" | |
git log --shortstat \ | |
| grep "files\? changed" \ | |
| awk '{files+=$1; inserted+=$4; deleted+=$6} END \ | |
{print "files changed", files, "lines inserted:", inserted, "lines deleted:", deleted}' |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment