title: find files returning basename and size
body: <p>In bash, I can get the basename (name without path) of found files like this:</p>
  
  <pre><code>find . -exec basename {} \;
  </code></pre>
  
  <p>and I can get the file size like this:</p>
  
  <pre><code>find . -exec ls -l {} \; | awk '{print $5}'
  </code></pre>
  
  <p>but I need to get the basename and filesize separated by a space.</p>
  
  <p>How do i combine those two commands correctly using one find operation?
  This code does not work:</p>
  
  <pre><code>find . -exec basename {} \; -exec ls -l {} | awk '{print $5}' \;
  
  awk: can't open file ;find: 
   source line number 1
  -exec: no terminating ";" or "+"
  </code></pre>
  
  <p>I am trying to create a fast duplicate file finder.  Using this list, I would do a sort and then use uniq to find all files that are duplicates using the criteria: a duplicate = same "basename" &amp; same "size" (without an md5 check).  </p>
  
  <p>So far, just making this initial list is where I am hung up syntactically (and maybe programmatically).  Please let me know if you have a better method.  It am trying to make it work using the most basic bash commands so it works on both linux and mac without installing anything.</p>