commands.getstatusoutput on NT
David Bolen
db3l at fitlinxx.com
Wed May 24 18:05:41 EDT 2000
David Bolen <db3l at fitlinxx.com> writes:
(...)
> For example, the command:
>
> s,r = commands.getstatusoutput("dir")
>
> could be replaced with:
>
> pipe = os.popen("dir 2>&1")
> r = pipe.read()
> s = pipe.status()
Small correction to my prior post - the final line should read:
s = pipe.close()
--
-- David
--
/-----------------------------------------------------------------------\
\ David Bolen \ E-mail: db3l at fitlinxx.com /
| FitLinxx, Inc. \ Phone: (203) 708-5192 |
/ 860 Canal Street, Stamford, CT 06902 \ Fax: (203) 316-5150 \
\-----------------------------------------------------------------------/
More information about the Python-list
mailing list