Traping output from os.system
Mark Hammond
MarkH at ActiveState.com
Sun Jul 2 10:47:41 EDT 2000
You want "popen". For non-windows platforms, "os.popen" is where you can
find it. For Win32 systems, you need the win32 extensions, and
"win32pipe.popen".
Mark.
--
markh at activestate.com - but if you think I speak for them, you dont know
Dick!
<f98ba at efd.lth.se> wrote in message news:8jn34q$kpn$1 at news.lth.se...
> Hi,
>
> I'm executing a command with os.system and are
> trying to capture the output into a python
> variable. The only I can find to do it in
> at the moment is to redirrect the output
> to a file and the read it. That feels wrong,
> isn't there another simple way??
>
> Thanks,
> Bjorn
More information about the Python-list
mailing list