changed:
-
<h2>Background</h2>
<p>I wanted to be able to use some shell scripts using PD I wrote in Linux on MacOSX, but the shell (Terminal) session does not know how to launch binaries from within Application Bundles.</p>
<p>On Linux, I can start pd by typing "pd" and hitting enter. On MacOSX, I can start the Pd App by typing "open -a Pd-extended" ... but I'd rather be able access the pd binary within the bundle directly so one script can work in Linux and OSX.</p>
<h2>How To</h2>
<p>The fix is pretty simple: Add an alias to the binaries within Pd-extended.app to your shell session.</p>
<p>Add the following to ~/.bash_profile:</p>
<pre>
# pd commandline
alias pd="/Applications/Pd-extended.app/Contents/Resources/bin/pd"
alias pdsend="/Applications/Pd-extended.app/Contents/Resources/bin/pdsend"
alias pdreceive="/Applications/Pd-extended.app/Contents/Resources/bin/pdreceive"
</pre>
<p>Restart the shell session and now the "pd", "pdsend", and "pdreceive" commands should launch their respective targets.</p>
<h3>Notes</h3>
~/.bash_profile is in your home directory, so any changes are only applied to your user account.