title: Extract directory path and filename
body: <p>I have a variable which has the directory path, along with the file name. I want to extract the filename alone from the Unix directory path and store it in a variable.</p>
  
  <pre><code>fspec="/exp/home1/abc.txt"  
  </code></pre>