open("ls -l |", "r") ??

Timothy Grant tjg at exceptionalminds.com
Fri Feb 9 13:32:32 EST 2001


On Fri, Feb 09, 2001 at 05:56:39PM +0000, steveFarris wrote:
> Hi all, is some variation of  the above possible in Python?
> 

>>> import os
>>> cmd = os.popen('ls -l')
>>> for l in cmd.readlines():
...   print l

-- 
Stand Fast,
    tjg.

Timothy Grant                         tjg at exceptionalminds.com
Red Hat Certified Engineer            www.exceptionalminds.com
Avalon Technology Group, Inc.                   (503) 246-3630
>>>>>>>>>>>>>Linux, because rebooting is *NOT* normal<<<<<<<<<
>>>>This machine was last rebooted:  23 days 22:41 hours ago<<




More information about the Python-list mailing list