praba kar wrote:

I agree above statement but When I delete a directory
os.system('rm -rf test')
0
if directory is not present then I again try to
delete
os.system('rm -rf test') now this time also It will print
0

As Roman Neuhauser says, this is the correct behavior of the -f switch for rm.


In [4]:os.system('rm -r foo')
rm: foo: No such file or directory
Out[4]:256

In [5]:os.system('rm -rf foo')
Out[5]:0

--
Robert Kern
[EMAIL PROTECTED]

"In the fields of hell where the grass grows high
 Are the graves of dreams allowed to die."
  -- Richard Harter

--
http://mail.python.org/mailman/listinfo/python-list

Reply via email to