Re: NSTask argument list
Re: NSTask argument list
- Subject: Re: NSTask argument list
- From: Graham Cox <email@hidden>
- Date: Sun, 26 Jun 2016 18:22:35 +1000
> On 26 Jun 2016, at 4:58 PM, Sandor Szatmari <email@hidden> wrote:
>
> You can either asynchronously monitor the task's output with notifications, or I have read about a new API, but never used it, -setReadabilityHandler:^(NSFileHandle* file)
>
> Sandor
>
Thanks!
I was able to set a readability handler on a NSPipe, set as stdout for the NSTask. ffmpeg has a -progress option which spews a bit of easily-parsed text to the pipe, so I was able to extract the info I wanted from that. All pretty straightforward in the end.
—Graham
_______________________________________________
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