Grep
Jump to navigation
Jump to search
grep with find
Given the common grep command
grep -R 'pattern' *
a corresponding find -exec command should add -H to include the filename prefix in the results. (This is needed because the filenames are given one at a time.)
find … -exec grep -H -R 'pattern' {} \;