Thanks Torsten

That definitely works great.  Sometimes I mistype the commands.  Is there a
way to get the error rather than an empty string?  

e.g. running

 LibC resultOfCommand: 'dur'

gives an empty string rather than 

  sh: dur: command not found

?

Paul





Torsten Bergmann wrote
> Hi Paul,
> 
> you can use:
> 
>     LibC resultOfCommand: 'dir'
> 
> which is part of standard image.
> 
> Bye
> T.
> 
> 
>> Gesendet: Montag, 04. Mai 2020 um 20:05 Uhr
>> Von: "PAUL DEBRUICKER" <

> pdebruic@

> >
>> An: "Any question about pharo is welcome" <

> pharo-users@.pharo

> >
>> Betreff: [Pharo-users] Pharo 8  - OSProcess or OSSubProcess or ?
>>
>> Hi -
>>
>> What  is the recommended way to  run a shell command  from Pharo 8 and 
>> get  the output from stdout into the image?
>>
>>
>> Thanks
>>
>> Paul
>>





--
Sent from: http://forum.world.st/Pharo-Smalltalk-Users-f1310670.html

Reply via email to