Skip to content

Instantly share code, notes, and snippets.

@rtanikella
Created June 23, 2018 19:06
Show Gist options
  • Save rtanikella/9a75565e54cffc25d67f07d366a5ef57 to your computer and use it in GitHub Desktop.
Save rtanikella/9a75565e54cffc25d67f07d366a5ef57 to your computer and use it in GitHub Desktop.
How to use grep and wc to count the number of occurrences of a string in a file, even when there are multiple occurrences of the string in a single line.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment