Both of these will open the application. The command can also be used
with a document file, as in:
open -a foo.app /path/to/some/document/xxx.foo
to open document /path/to/some/document/xxx.foo with foo.app. If
foo.app isn't in one of the usual places (e.g. /Applications) it may
be necessary to use a full pathname. You can also use open with just
a document path to open the document with the default application
(e.g. open xxx.foo). There are other forms too (e.g. -b BUNDLE-ID),
but they aren't universal to all OS X versions (the two referenced in
the original posts go all the way back to 10.1.x, but -b was new with
10.4 IIRC).
See "man open" for the full details.
Also, be sure to follow the usual safety precautions when using
Runtime.exec (use the String[] form, drain the output streams, etc.).
The issue has been beaten to death in the past, I think there are
code examples in the archives of how to do it right.
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Java-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription: http://lists.apple.com/mailman/options/java-dev/email@hidden