Re: How to pass command line parameters to Cocoa App
Re: How to pass command line parameters to Cocoa App
- Subject: Re: How to pass command line parameters to Cocoa App
- From: Scott Ribe <email@hidden>
- Date: Tue, 16 Aug 2011 09:08:42 -0600
On Aug 16, 2011, at 8:54 AM, Abdul Sowayan wrote:
> What I would like to have is launch my application from the GUI and somehow
> pass the command line parameters to it. If I had to guess, this would be
> encoded in the Info.plist file in the bundle. It is not clear to me how to
> do that. Any feedback would be greatly appreciated.
I don't think you can do that; the whole idea of command-line args to GUI apps just doesn't have a place in Mac OS.
Oddly though, I think there is a plist key which lets you specify environment variables, so you can have the same effect. I don't remember the key name, but it's LSxxx since it is a LaunchServices key.
--
Scott Ribe
email@hidden
http://www.elevated-dev.com/
(303) 722-0567 voice
_______________________________________________
Cocoa-dev mailing list (email@hidden)
Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden