Answers for "exclude grep"

3

grep exclude directory

grep -rli --exclude-dir={dir1,dir2,dir3} keyword /path/to/search
Posted by: Guest on October-08-2020
0

grep exclude files

Just filter your output with:
grep -v "excluded_pattern"
Example to get all not txt files in current directory.
ls | grep -v .txt
Posted by: Guest on October-22-2020

Code answers related to "Shell/Bash"

Browse Popular Code Answers by Language