Last active
April 1, 2025 02:43
-
Star
(389)
You must be signed in to star a gist -
Fork
(44)
You must be signed in to fork a gist
-
-
Save mandiwise/dc53cb9da00856d7cdbb to your computer and use it in GitHub Desktop.
A command to calculate lines of code in all tracked files in a Git repo
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Reference: http://stackoverflow.com/questions/4822471/count-number-of-lines-in-a-git-repository | |
$ git ls-files | xargs wc -l |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
An improvement based on what has already been said, by the way thanks for the tip.
Line counter for child folders with aggregator removing image files (webp|ttf|png|jpg|jpeg) :
How to use:
counter.sh: