1、需求:查看某个人的所有提交,用于总结报告
方法:
git log --author="author"
2、需求:查看某个人的所有提交,逆序
方法:
git log --reverse
3、需求:查看某个人的提交统计信息
方法:
git log --author="zhangphil" --oneline | wc -l
git log --author="_your_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 }'
参考
博客介绍了使用Git时的几个需求及对应方法,包括查看某个人的所有提交用于总结报告、逆序查看某个人的所有提交,以及查看某个人的提交统计信息,还给出了相关参考内容。
1万+

被折叠的 条评论
为什么被折叠?



