On Aug 21, 3:09 pm, avishay <[EMAIL PROTECTED]> wrote:
> Hello
> I'm trying to chain two programs with a pipe (the output of one
> feeding the input of the other). I managed to capture the output and
> feeding the input of each program independently with popen, but how do
> I tie them together? Is there a solution that works equally on all
> platforms?
Not sure on non-unix platforms, but in unix like platforms it's best
to reuse shell's power.
>>> import commands
>>> commands.getoutput('ls | wc')
' 4 4 24'
>>>
Thanks,
Karthik
>
> Thanks,
> Avishay
--
http://mail.python.org/mailman/listinfo/python-list