Executing a system command without waiting for a response

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

Executing a system command without waiting for a response

ZuLuuuuuu
Hello,

I was wondering what is the best and easiest way to execute a system command without waiting for a response (I guess it is called asynchronous process?).

Smalltalk#system: waits for the response. For example, when I do:

Smalltalk system: 'gedit'

gedit is opened but the interpreter is locked until I close gedit. I want the interpreter not to be locked and I want gedit to be still open even if I quit the interpreter. Is something like this possible?
Canol Gökel
Reply | Threaded
Open this post in threaded view
|

Re: Executing a system command without waiting for a response

Paolo Bonzini-2
On Sun, Jul 31, 2011 at 00:08, ZuLuuuuuu <[hidden email]> wrote:

> Hello,
>
> I was wondering what is the best and easiest way to execute a system command
> without waiting for a response (I guess it is called asynchronous process?).
>
> Smalltalk#system: waits for the response. For example, when I do:
>
> Smalltalk system: 'gedit'
>
> gedit is opened but the interpreter is locked until I close gedit. I want
> the interpreter not to be locked and I want gedit to be still open even if I
> quit the interpreter. Is something like this possible?

You can use a "fake" pipe (FileStream class>>#popen:dir:) for this.

Paolo

_______________________________________________
help-smalltalk mailing list
[hidden email]
https://lists.gnu.org/mailman/listinfo/help-smalltalk