Grep text recursively in Unix
Tuesday, September 2, 2008
Using the pattern keyword:
grep pattern * */* */*/* 2>/dev/null
The simplistic approach using find is:
find /startdir -exec grep whatever {} dev/null \;
That's not necessarily very efficient. Using xargs can help
find . -name *.xml | xargs grep whatever
Posted bySeshu Karthick at 8:56 AM
Labels: unix
0 comments:
Subscribe to:
Post Comments (Atom)