searching in files
Joshua Daniel Franklin
jdf.lists at gmail.com
Fri Jun 27 09:45:41 CDT 2008
On Fri, Jun 27, 2008 at 2:28 AM, Kevin Davidson
<kevin at indigospring.co.uk> wrote:
> Not very Dell related, but you probably want something like this:
> find . -name FILENAMEPATTERN -exec grep -n SEARCHPATTERN {} /dev/null \;
Yep, or you can use xargs to the same effect:
find -name *tex | xargs grep LaTeX
Or, if you've got control chars or spaces in the filenames:
find -name "*tex" -print0 | xargs -0 grep LaTeX
More information about the Linux-PowerEdge
mailing list