Skip to content

Instantly share code, notes, and snippets.

@cgravier
Created September 3, 2012 07:57
Show Gist options
  • Save cgravier/3607749 to your computer and use it in GitHub Desktop.
Save cgravier/3607749 to your computer and use it in GitHub Desktop.
Count lines in a project, stripping comments and empty lines (folder and subfolders, look for php, as, sql, css, java, jsp files)
find . | egrep '\.php|\.as|\.sql|\.css|\.java|\.jsp' | grep -v '\.git' | xargs cat | sed '/^\s*$/d' | wc -l
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment