I am working on writing some scripts to grep certain directories, but these directories contain all sorts of file types.
grep
I want to grep jus
The below answer is good:
grep -r -i --include \*.h --include \*.cpp CP_Image ~/path[12345] | mailx -s GREP email@domain.com
But can be updated to:
grep -r -i --include \*.{h,cpp} CP_Image ~/path[12345] | mailx -s GREP email@domain.com
Which can be more simple.