[IPython-dev] running shell command from engine

Fernando Perez fperez.net at gmail.com
Thu Jun 19 14:29:20 EDT 2014


Sure! Popen won't give you an actual result that's very useful, you'll need
to decide whether to capture stdout/err, to use pipes, etc. But
subprocess/popen are just python functions like any other, so you can use
them all the same...

f


On Thu, Jun 19, 2014 at 6:59 AM, Antonio González Peña <antgonza at gmail.com>
wrote:

> Hello,
>
> Is it possible to run a shell command from an engine? For example:
> result = v.map(lambda job: Popen(['/bin/sh', job]), jobs)
>
> Thanks
>
> --
> Antonio
> _______________________________________________
> IPython-dev mailing list
> IPython-dev at scipy.org
> http://mail.scipy.org/mailman/listinfo/ipython-dev
>



-- 
Fernando Perez (@fperez_org; http://fperez.org)
fperez.net-at-gmail: mailing lists only (I ignore this when swamped!)
fernando.perez-at-berkeley: contact me here for any direct mail
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140619/1ff412f4/attachment.html>


More information about the IPython-dev mailing list