-
-
Notifications
You must be signed in to change notification settings - Fork 1.1k
Open
Description
It would be cool, if there was an option to show lines of code per Git author using git blame.
I found this command somewhere some time ago that does exactly that (note that it filters for java and kt files here):
git ls-tree --name-only -z -r HEAD|egrep -z -Z -E '\.(java|kt)$' |xargs -0 -n1 git blame --line-porcelain|grep "^author "|sort|uniq -c|sort -nr
The output looks like this:
22916 author jannis
2076 author other name
1576 author another name
1552 author 3rd name
The problem is that this also counts blank lines and comments which cloc already solves.
Feel free to just close if this is out of scope for cloc. Thank you for reading and the best line counter I know :)
timfraedrich, ZandercraftGames and Safari77
Metadata
Metadata
Assignees
Labels
No labels