Skip to content

Instantly share code, notes, and snippets.

@RackReaver
Last active May 10, 2021 17:51
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save RackReaver/76ce1520ffcbe258b6cade05174fd5aa to your computer and use it in GitHub Desktop.
Save RackReaver/76ce1520ffcbe258b6cade05174fd5aa to your computer and use it in GitHub Desktop.
bash:script: count code lines (git)
# While inside of git repository this command will output lines of code written by each author.
git ls-files | while read f; do git blame -w --line-porcelain -- "$f" | grep -I '^author '; done | sort -f | uniq -ic | sort -n
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment