title: How to remove last subdir from path using tcl?
body: <pre><code>c:\root\machine\spec\detail\
  z:\test\room\tool\
  </code></pre>
  
  <p>i want to remove the last subdir to become like this :</p>
  
  <pre><code>c:\root\machine\spec\
  z:\test\room\
  </code></pre>
  
  <p>How to do it using TCL ?</p>
  
  <p>Thanks</p>