Re: [Pharo-users] Using the new OSProcess still no Stdout string

2016-03-08 Thread Pierce Ng
On Sat, Mar 05, 2016 at 02:19:10PM +, Dimitris Chloupis wrote: > thanks for freezing my image !!! Ar :D > > On Sat, Mar 5, 2016 at 10:44 AM john pfersich wrote: > > p := (PipeableOSProcess command: 'netstat -a | grep LISTEN | grep 27017'). netstat -an Option n avoids DNS lookup wh

Re: [Pharo-users] Using the new OSProcess still no Stdout string

2016-03-05 Thread Dimitris Chloupis
thanks for freezing my image !!! Ar :D On Sat, Mar 5, 2016 at 10:44 AM john pfersich wrote: > Well, I have to take back the comment on command:. I have this code > snippet that gets output from a command: > > | p d | > p := (PipeableOSProcess command: 'netstat -a | grep LISTEN | grep

Re: [Pharo-users] Using the new OSProcess still no Stdout string

2016-03-05 Thread john pfersich
I just loaded the latest image and vm using curl get.pharo.org/alpha+vmLatest | bash and OSProcess and CommandShell seem to work OK. On Friday, March 4, 2016, john pfersich wrote: > You want to use waitForCommand: instead of command:, like > > Transcript show: (PipeableOSProcess waitForCo

Re: [Pharo-users] Using the new OSProcess still no Stdout string

2016-03-05 Thread john pfersich
Well, I have to take back the comment on command:. I have this code snippet that gets output from a command: | p d | p := (PipeableOSProcess command: 'netstat -a | grep LISTEN | grep 27017'). p keepInitialStdOutOpen: true. d := Delay forMilliseconds: 500. d wait. [Transcript show: (p next: 300);

Re: [Pharo-users] Using the new OSProcess still no Stdout string

2016-03-04 Thread john pfersich
You want to use waitForCommand: instead of command:, like Transcript show: (PipeableOSProcess waitForCommand: 'whoami') output command: doesn't wait for output and is useful only for commands that don't return anything. It's kind of useless for anything that returns values. I haven't tried this o