How would I count the total number of lines present in all the files in a git repository?
git ls-files gives me a list of files tracked by git.
git ls-files
If you want to get the number of lines from a certain author, try the following code:
git ls-files "*.java" | xargs -I{} git blame {} | grep ${your_name} | wc -l