grep pattern code example
Example 1: grep -r
grep -r 'text goes here' path_goes_here
Example 2: grep without pattern
Just filter your output with:
grep -v "excluded_pattern"
Example to get all not txt files in current directory.
ls | grep -v .txt