- If you want to start a MacOSX applications from a terminal (or a shell script) you have to use the open command, i.e.:
open /Application/Firefox.app
(based on xahlee.org) - If you need to write a wrapper starting a binary file (which is inside of a MacOSX app) with some options you can use following construction:
HERE=`dirname $0`; $HERE/name.x -options
The same construction is useful if you need to set some environment variables. - Sometimes is it necessary to have a location of an app, but apps can be place in a very strange places. MacOSX binaries are located third level deep inside of an app, so the following command save location of an app in the TOPDIR variable:
TOPDIR=`cd $HERE/../../../; pwd`
Kind of my extended memory with thoughts mostly on Linux and related technologies. You might also find some other stuff, a bit of SF, astronomy as well as old (quantum) chemistry posts.
Search This Blog
Friday, December 21, 2007
Tips for starting MacOSX apps
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment