Skip to content

Instantly share code, notes, and snippets.

@harrytallbelt
Created October 31, 2017 16:07
Show Gist options
  • Save harrytallbelt/a45c8d87d772aaab8d135c50ace9be1d to your computer and use it in GitHub Desktop.
Save harrytallbelt/a45c8d87d772aaab8d135c50ace9be1d to your computer and use it in GitHub Desktop.
helpful bash commands
# count lines in all inner js files of a project
cat `find . | grep -v 'node_modules' | grep '.*.js$'` | wc -l
# list all the js files that contain a word
grep -v 'node_modules' | grep '.*.js$' | xargs grep 'SEARCHWORD' -l
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment