-
-
Save Snegovikufa/f0bc8248e5f480d76939937e221a4c96 to your computer and use it in GitHub Desktop.
Git changed lines per author
This file contains 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/sh | |
git shortlog -sn | awk ' {print $2, $3, $4} ' > names.txt | |
cat names.txt | while read cn | |
do | |
name="$(echo $cn | sed -e 's/\r//g')" | |
echo $name | |
git log --no-merges -p -w --shortstat --author="$name" --since="1 Jan, 2017" -p -- . ':(exclude)*.xml' ':(exclude)*.png' ':(exclude)*.g.cs' ':(exclude)*.Designer.cs' ':(exclude)lib/*' ':(exclude)*.csproj' | grep -E "fil(e|es) changed" | awk '{files+=$1; inserted+=$4; deleted+=$6} END {print " files changed: ", files, "lines inserted: ", inserted, "lines deleted: ", deleted }' | |
done | |
rm names.txt |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment