Created
June 22, 2010 03:16
-
-
Save onishi/447886 to your computer and use it in GitHub Desktop.
check your responsibility
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/sh | |
if [ $# -eq 2 ] | |
then | |
i=$2 | |
else | |
i=`whoami` | |
fi | |
declare -i mine=`git blame $1 | grep -i $i | wc -l` | |
declare -i total=`cat $1 | wc -l` | |
declare -i rate=$mine*100/$total | |
echo $rate'%' |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
blamerate /path/to/file author