Friday, February 6, 2009

Looking for content within files in Linux

Within your directory, type the following command:

sudo find . -print xargs grep "pattern to search for"

or if you have the name type, you can try

sudo find . -name "*.pl" xargs grep "pattern to search for"

No comments: