This is a question more appropos to xcode-users, but I'll answer
anyway :).
i thought it might've been, but then i thought maybe Carbon had ways
to snarf the argv, also ..
Xcode's pseudo-terminal execution environment, both the
basic Run command and the gdb shell of the Debug command, runs the
command through something similar to this Terminal process:
$ cd /path/to/app/bundle
$ ./Application.app/Contents/MacOS/Application <the arguments you specified>
got it.. thanks for clearing that up. suck for me, but okay.
Info.plist/prefs it is ..
plenty that do in the Windows and X11 worlds). It's not
user-friendly. I can't imagine why you'd want to do this.
i can't imagine why anyone would think -all- users are too stupid to
want to use cmd line args. i mean, c'mon .. i can do fprintf()'s to
stderr, why can't i suck up my argv's .. its just .. ermm ..
whatever. lets not get political.
If you
want to supply configuration options, use preferences.
looks like i have to.
Also, commandline arguments aren't reliable. Terminal users
won't get the ones you define, you can't do it directly via
Info.plist, and if you could, powerusers have a tendency to play
with commandline arguments when they see them and you're inviting
confusion at best that way.
my users are not 'the general Apple public', they are testers and
debug'ers and people otherwise using my tools to perform specific
tasks. if there were a way to make it easy to just keep using
argv's, i'd prefer that; i don't want to have to special-case some
Apple-only code in my project just to get this working.. but i will
if, absolutely, i'm not allowed to think in argc/argv terms in this
Carbon project.
Argc/argv were and are a great way to alter a CLI program's
behavior, but this is the GUI age and a GUI OS.
its only GUI on top, yo.
The commandline is
pure gibberish to the majority of Mac users, in my experience. Don't
get caught in the idea that you have to do it that way just because
you always have :)
okay, but don't get caught in the idea that there are only imperical
ways to define what a USER is. my apps aren't for general clueless
Apple public; they're for people who are using the Apple platform and
want to run my apps, which mostly run .. elsewhere .. where argc/argv
style thinking is still acceptable .. and all i want to do is avoid
having to Apple'ize this one, specific, aspect of my app.
it'd be far more fun if i could just parse argv -somehow- and leave
it at that, and not have to write throw-away code that won't make
sense anywhere else ..
For the record, one way to actually do what you want would be to
write a tiny wrapper program as your CFBundleExecutable that does
this (written in Mail.app, standard disclaimers apply):
int main( int argc, char **argv )
{
...
return 0;
}
good lord, what an ugly hack.. but, thanks for taking the time to present it.
i'll look at Info.plist monkey-business as an immediate solution to
the problem, which i will attempt to forget about as soon as possible
..
--
;
Jay Vaughan
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Carbon-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/carbon-dev/email@hidden