title: How to find basename of path via pipe
body: <p>This doesn't work:</p>
  
  <pre><code>find "$all_locks" -mindepth 1 -maxdepth 1 -type d | basename
  </code></pre>
  
  <p>apparently basename cannot read from stdin - in any case basename requires at least one argument.</p>