Issue
How to grep a string or a text in a directory and all its subdirectories'files in LINUX ??
Solution
If your grep supports -R
, do:
grep -R 'string' dir/
If not, then use find
:
find dir/ -type f -exec grep -H 'string' {} +
Answered By - John Kugelman