Skip to content

Instantly share code, notes, and snippets.

@nhevia
Created November 17, 2020 13:55
Show Gist options
  • Save nhevia/c429095d9d8265e9d291cce099a24186 to your computer and use it in GitHub Desktop.
Save nhevia/c429095d9d8265e9d291cce099a24186 to your computer and use it in GitHub Desktop.
A command to show amount of lines in a git repository, excluding files
$ git ls-files --exclude-standard -- ':!:**/*.[pjs][npv]g' ':!:**/*.eslintrc' ':!:package-lock.json' | xargs wc -l
// Excludes png, jpg, svg and package.json files.
// For excluding other configuration files (eslint for example): ':!:**/*.eslintrc'
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment