赞
踩
说明:需要打开git bash窗口 切换到要操作的项目的根目录才可使用(要有.git文件);
git log --since="2021-03-01" --before="2022-01-09" --author="username" --pretty=tformat: --numstat | awk '{ add += $1; subs += $2; loc += $1 - $2 } END { printf "added lines: %s, removed lines: %s, total lines: %s\n", add, subs, loc }'
git log --format='%aN' | sort -u | while read name; do echo -en "$name\t"; git log --author="$name" --pretty=tformat: --numstat | awk '{ add += $1; subs += $2; loc += $1 - $2 } END { printf "added lines: %s, removed lines: %s, total lines: %s\n", add, subs, loc }' -; done
git log --pretty='%aN' | sort | uniq -c | sort -k1 -n -r | head -n 5
git log --format='%aN' | sort -u | while read name; do echo -en "$name\t"; git log --since=2022-06-14 --before=2022-06-15 --author="$name" --pretty=tformat: --numstat | awk '{ add += $1; subs += $2; loc += $1 - $2 } END { printf "added lines: %s, removed lines: %s, total lines: %s\n", add, subs, loc }' -; done
Copyright © 2003-2013 www.wpsshop.cn 版权所有,并保留所有权利。