processing unix command output lists

Martin Franklin martin.franklin at waii.com
Wed Mar 29 02:28:28 EST 2000


How about.......

import os
command = os.popen('ps -ef | grep whatever','r')
output_list = command.readlines()
return_code = command.close()


> >Hi,
> >In python is there a way to get the output of a unix comamnd
> >in the form of list or something.
> >example:







More information about the Python-list mailing list