title: Bash Script to find files
body: <p>Good day,
  I've found an easy way to find files that have certain content, but I would like to create a bash script to do it quickier, </p>
  
  <p>The script is:</p>
  
  <pre><code>#!/bin/bash
  DIRECTORY=$(cd `dirname .` &amp;&amp; pwd)
  ARGUMENTS="'$@'"
  
  echo find: $ARGUMENTS on $DIRECTORY
  find $DIRECTORY -iname '*' | xargs grep $ARGUMENTS -sl
  </code></pre>
  
  <p>So if I write:</p>
  
  <pre><code>$ script.sh text
  </code></pre>
  
  <p>It should find in that directory files that contains 'text'</p>
  
  <p>But when I execute this script it always fails, but the echo command shows exactly what I need, what's wrong with this script?</p>
  
  <p>Thank you!</p>
  
  <p>Luis</p>
  
  <p>References: <a href="http://www.liamdelahunty.com/tips/linux_find_string_files.php" rel="nofollow">http://www.liamdelahunty.com/tips/linux_find_string_files.php</a></p>