Re: NSTask is Weird

2008-09-11 Thread J. Todd Slack
Thanks everyone, Yes, over thinking about it. I was escaping and quoting, etc. Works now! -Jason On Sep 11, 2008, at 8:48 AM, Clark Cox wrote: On Thu, Sep 11, 2008 at 4:03 AM, J. Todd Slack <[EMAIL PROTECTED]> wrote: Hi, I guess what I dont get is when you pass arguments that are not

Re: NSTask is Weird

2008-09-11 Thread Clark Cox
On Thu, Sep 11, 2008 at 4:03 AM, J. Todd Slack <[EMAIL PROTECTED]> wrote: > Hi, > > I guess what I dont get is when you pass arguments that are not simple like: > >>[task setLaunchPath: @"/bin/ls"]; >>[task setArguments: [NSArray arrayWithObjects: @"ls", @"-al", @"/", >> nil]]; > >

Re: NSTask is Weird

2008-09-11 Thread Michael Ash
On Thu, Sep 11, 2008 at 7:03 AM, J. Todd Slack <[EMAIL PROTECTED]> wrote: > Hi, > > I guess what I dont get is when you pass arguments that are not simple like: > >>[task setLaunchPath: @"/bin/ls"]; >>[task setArguments: [NSArray arrayWithObjects: @"ls", @"-al", @"/", >> nil]]; > >

Re: NSTask is Weird

2008-09-11 Thread Sherm Pendley
On Thu, Sep 11, 2008 at 7:03 AM, J. Todd Slack < [EMAIL PROTECTED]> wrote: > Hi, > > I guess what I dont get is when you pass arguments that are not simple > like: > > [task setLaunchPath: @"/bin/ls"]; >>[task setArguments: [NSArray arrayWithObjects: @"ls", @"-al", @"/", >> nil]];

Re: NSTask is Weird

2008-09-11 Thread J. Todd Slack
Hi, I guess what I dont get is when you pass arguments that are not simple like: [task setLaunchPath: @"/bin/ls"]; [task setArguments: [NSArray arrayWithObjects: @"ls", @"-al", @"/", nil]]; What about a command that takes arguments like: --segments /Users/slack/music/iTunes/iTu

Re: NSTask is Weird

2008-09-10 Thread Jim Correia
On Sep 11, 2008, at 12:12 AM, Andrew Farmer wrote: Arguments needs to be an array containing one element per argument to the task That is correct. including argv[0] as the name of the executable. That advice is incorrect for NSTask. Consider the output of the following code, which follow

Re: NSTask is Weird

2008-09-10 Thread Andrew Farmer
On 10 Sep 08, at 20:24, J. Todd Slack wrote: Here it the command I am executing: /usr/local/bin/pymp3cut --segment "/Users/slack/Library/Application Support/Ring-Maker/tmp/amber",00:00:11,00:00:36 "/Users/slack/Music/ iTunes/iTunes Music/311/Unknown Album/01 Amber.mp3" I get this from the d

NSTask is Weird

2008-09-10 Thread J. Todd Slack
Hi All, NSTask seems weird to me. I am trying to call a command-line app with arguments. When I execute in a Terminal it works, but from my application is fails. Here it the command I am executing: /usr/local/bin/pymp3cut --segment "/Users/slack/Library/Application Support/Ring-Maker/tmp/am