This commit is contained in:
RodrigoHahn 2016-03-01 19:15:39 +00:00
commit 08af919020

View file

@ -6,6 +6,10 @@ if [ $# -ne 2 ]; then
fi fi
AUTHOR=$1 AUTHOR=$1
if [ "$1" = "random" ]; then
AUTHOR=$(git log --all --format='%aN <%cE>' | sort -u | shuf | head -n 1)
fi
AUTHOR_NAME=$(echo $AUTHOR | perl -wlne '/^(.*)\s*<.*>$/ and print $1') AUTHOR_NAME=$(echo $AUTHOR | perl -wlne '/^(.*)\s*<.*>$/ and print $1')
AUTHOR_EMAIL=$(echo $AUTHOR | perl -wlne '/^.*\s*<(.*)>$/ and print $1') AUTHOR_EMAIL=$(echo $AUTHOR | perl -wlne '/^.*\s*<(.*)>$/ and print $1')
COMMIT=$(git rev-parse --short $2) COMMIT=$(git rev-parse --short $2)