<?xml version="1.0" encoding="utf-8"?>
<rss xmlns:atom="http://www.w3.org/2005/Atom" version="2.0"><channel><title>Tech-Recipes - Latest Comments in Recursive grep</title><link>http://tech-recipes.disqus.com/</link><description>Cookbook of Tech Tutorials</description><atom:link href="https://tech-recipes.disqus.com/recursive_grep_unix_tech_recipes/latest.rss" rel="self"></atom:link><language>en</language><lastBuildDate>Tue, 16 Nov 2010 14:36:28 -0000</lastBuildDate><item><title>Re: Recursive grep</title><link>http://www.tech-recipes.com/rx/732/recursive-grep/#comment-97986628</link><description>&lt;p&gt;Worthless.&lt;/p&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Qwertyboy</dc:creator><pubDate>Tue, 16 Nov 2010 14:36:28 -0000</pubDate></item><item><title>Re: Recursive grep</title><link>http://www.tech-recipes.com/rx/732/recursive-grep/#comment-37486141</link><description>&lt;p&gt;We could probably go on and on...this works well on most...&lt;/p&gt;&lt;p&gt;find -maxdepth 1 -type f -print0 | xargs grep -F 'example' &lt;br&gt;  #Will Search all regular files for 'example' in current dir&lt;/p&gt;&lt;p&gt;find -type f -print0 | xargs -r0 grep -F 'example'  &lt;br&gt; #Will Search all regular files for 'example' in current dir and below&lt;br&gt;&lt;/p&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">reggie</dc:creator><pubDate>Mon, 01 Mar 2010 13:00:30 -0000</pubDate></item><item><title>Re: Recursive grep</title><link>http://www.tech-recipes.com/rx/732/recursive-grep/#comment-4467848</link><description>&lt;p&gt;This is a fantastic tip, thank you!&lt;/p&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Lee</dc:creator><pubDate>Wed, 17 Dec 2008 17:07:44 -0000</pubDate></item><item><title>Re: Recursive grep</title><link>http://www.tech-recipes.com/rx/732/recursive-grep/#comment-2768759</link><description>&lt;p&gt;For those of you with a really stripped down config with no xargs and a find that doesn't support -exec, the old fashioned way:&lt;/p&gt;&lt;p&gt;&lt;code&gt;for i in `find &amp;lt;path&amp;gt;`; do grep &amp;lt;pattern&amp;gt; $i; done&lt;/code&gt;&lt;/p&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Anonymous</dc:creator><pubDate>Thu, 21 Jun 2007 04:41:42 -0000</pubDate></item><item><title>Re: Recursive grep</title><link>http://www.tech-recipes.com/rx/732/recursive-grep/#comment-2768758</link><description>&lt;p&gt;find|xargs grep 'search text'&lt;/p&gt;&lt;p&gt;is easier to type :-)&lt;/p&gt;&lt;p&gt;xargs rocks.&lt;/p&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Anonymous</dc:creator><pubDate>Sun, 27 May 2007 06:51:15 -0000</pubDate></item><item><title>Re: Recursive grep</title><link>http://www.tech-recipes.com/rx/732/recursive-grep/#comment-2768757</link><description>&lt;p&gt;It's so great. Thanks.&lt;/p&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Anonymous</dc:creator><pubDate>Tue, 15 Nov 2005 16:11:13 -0000</pubDate></item><item><title>Re: Recursive grep</title><link>http://www.tech-recipes.com/rx/732/recursive-grep/#comment-2768756</link><description>&lt;p&gt;find /users/ -type f -name "*" -exec grep -ls sqlload {} ;&lt;br&gt;It gives output like this:&lt;br&gt;/users/hattb/shirley_test_file&lt;/p&gt;&lt;p&gt;The -type f switch tells it to only look in text files.&lt;br&gt;If you want to redirect the output to a file: &lt;br&gt;find /users/hattb -type f -name "*" -exec grep -ls sqlload {} ; &amp;gt;out.txt&lt;/p&gt;&lt;p&gt;Hope this helps,&lt;br&gt;Shirley&lt;/p&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Anonymous</dc:creator><pubDate>Wed, 03 Aug 2005 03:28:50 -0000</pubDate></item><item><title>Re: Recursive grep</title><link>http://www.tech-recipes.com/rx/732/recursive-grep/#comment-2768755</link><description>&lt;p&gt;find . -name "*" -exec grep &amp;lt;pattern&amp;gt; {} /dev/null ;&lt;/p&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">seacoder</dc:creator><pubDate>Thu, 30 Jun 2005 04:00:39 -0000</pubDate></item><item><title>Re: Recursive grep</title><link>http://www.tech-recipes.com/rx/732/recursive-grep/#comment-2768754</link><description>&lt;p&gt;that's great and all, but you dont get filenames&lt;/p&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Anonymous</dc:creator><pubDate>Thu, 28 Apr 2005 10:30:36 -0000</pubDate></item><item><title>Re: Recursive grep</title><link>http://www.tech-recipes.com/rx/732/recursive-grep/#comment-2768753</link><description>&lt;p&gt;Thank you so much,&lt;/p&gt;&lt;p&gt;It is one of those days.. I spent almost an hour for this.....&lt;/p&gt;&lt;p&gt;Best, peace...&lt;br&gt;Hal&lt;/p&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">htihan</dc:creator><pubDate>Mon, 18 Apr 2005 04:25:13 -0000</pubDate></item></channel></rss>