launching an OSX bundle

Scott Morrow scott at elementarysoftware.com
Tue Jul 29 02:25:59 EDT 2008


Hello Andre,

Thanks for the lesson!

-Scott Morrow

On Jul 28, 2008, at 9:49 PM, Andre Garzia wrote:

> Scott,
>
> using something like
>
> launch -a <app name>
>
> will free you from dealing with path references, for example:
>
> launch -a firefox
>
> will launch firefox no matter where firefox.app is located, courtesy
> of launcservices framework or whatever keeps track of the filesystem
> these days...
>
> As for having a difference, I know one, calling the binary direct will
> "freeze" the process context that called it, for example if you open a
> terminal window and use a command to call the binary, you'll see that
> it doesn't return till the application exits, so, as far as the
> terminal opened is concerned, the application is running and blocking
> further interaction in that context, also you'll be able to see data
> sent for STDOUT in the terminal. This is a good way to display debug
> info for example, make your app output to stdout and call the binary.
>
> If you use launch, then the application is launched in another
> context, so, if you open a terminal and call launch you'll see that it
> returns immediately no matter if the apps keep running or not. Also
> stdin/stdout/stderr will be different then they are from launching by
> calling the binary.
>
> So what method you want depends on what you need. Do you need to
> capture output, then calling the binary is the best option, if you
> want to launch an app and forget about it, then launch will do it. I
> think that calling shell() with the binary reference will block until
> the called app exits but I am not sure.
>
> hope this helps
> andre
>
> On Sun, Jul 13, 2008 at 7:13 PM, Scott Morrow
> <scott at elementarysoftware.com> wrote:
>> I'm wondering if issuing the "launch" command to:
>>
>> /Applications/OSX bundle.app
>>
>> produces different results than issuing the command to
>>
>> OSX bundle.app/Contents/MacOS/theBinFile
>>
>> Both seem to launch the app.  Just curious if there is a difference  
>> that I
>> might not be noticing?
>>
>>
>> Scott Morrow
>>
>> Elementary Software
>> (Now with 20% less chalk dust!)
>> web       http://elementarysoftware.com/
>> email     scott at elementarysoftware.com
>>
>>
>> _______________________________________________
>> use-revolution mailing list
>> use-revolution at lists.runrev.com
>> Please visit this url to subscribe, unsubscribe and manage your  
>> subscription
>> preferences:
>> http://lists.runrev.com/mailman/listinfo/use-revolution
>>
>
>
>
> -- 
> http://www.andregarzia.com All We Do Is Code.
> _______________________________________________
> use-revolution mailing list
> use-revolution at lists.runrev.com
> Please visit this url to subscribe, unsubscribe and manage your  
> subscription preferences:
> http://lists.runrev.com/mailman/listinfo/use-revolution




More information about the use-livecode mailing list