title: how to grep large number of files?
body: <p>I am trying to <code>grep</code> 40k files in the current directory and i am getting this error.</p>
  
  <pre><code>for i in $(cat A01/genes.txt); do grep $i *.kaks; done &gt; A01/A01.result.txt
  -bash: /usr/bin/grep: Argument list too long
  </code></pre>
  
  <p>How do one normally <code>grep</code> thousands of files?</p>
  
  <p>Thanks
  Upendra</p>