title: Is it possible to execute a command relative to a Terminal shell script?
body: <p>I have a Terminal shell script file <code>start.command</code> that I launch from finder with:</p>
  
  <pre><code>ls -l
  </code></pre>
  
  <p>The file is in <code>~/foo</code> but list <code>~</code>, can I get the path of it's containing dir. I'd like to launch an application that is in the same folder as the file when the user runs the <code>.command</code> but it seems like I would need the absolute path to the file for that to work.</p>