os module question

Cameron Laird claird at lairds.com
Sun Mar 28 08:13:38 EST 2004


In article <c46bvt$527$1 at news2.netvision.net.il>,
Miki Tebeka  <miki.tebeka at zoran.com> wrote:
>Hello Sean,
>
>> os.system() always seems to return all output so I don't know why that
>> doesn't work.
>The return value is the exit status.
>
>Miki

... which leaves the question of what *will* satisfy Rasputin.
While I don't seem to have fortune(1) on any of my hosts today,
I believe
  import os
  print os.popen("fortune -f").read()
is it.
-- 

Cameron Laird <claird at phaseit.net>
Business:  http://www.Phaseit.net



More information about the Python-list mailing list