Open application from OSX Terminal with debug printouts
12,082
Solution 1
The solution is to specify the absolute path of the application, rather than the path relative to the current directory.
For example,
open /home/matt/MyApp.app
Solution 2
.app Applications are directories, from the terminal open the executable rather than the whole directory, e.g...
open /Applications/my.app/Contents/MacOS/my
If you're not sure of the executable file name within the app contents, inspect my.app/Contents/Info.plist CFBundleExecutable
.
Comments
-
Matt over 1 year
I can open an application using
open
, like this:open ./MyApp.app
But this doesn't display the application's debug printouts - which I need.
If I locate the binary inside the package manually and run that, I get the printouts fine, but I want to be able to just run the application.
-
Matt almost 13 yearsI want the application to run hidden but must also use cocoa. This works fine if I set "Application is agent" in the plist file and run it as an actual application. If I just run the binary directly, it doesn't run hidden and displays the dock+menu components.
-
Matt almost 13 yearsActually if I run the binary by specifying the path rather than cd-ing to it, it works fine. Cool.
-
-
HikeMike over 12 yearsThis shouldn't make any difference.