Remove diretory with files in it

Greg Fortune lists at
Sun Aug 25 07:09:45 CEST 2002

check rmtree(path) in shutil.  Just learned about this module myself a 
couple days ago.  Kinda odd that copy and removing a directory would be in 
a module other than os, but now we know where to find them ;o)


samuel Parkay wrote:

> I can;'t  seem to make the os.rmdir()path) command to work the way I
> need it .  I would like it to be like" rm -rf" in unix .  It keeps
> throwing an exception about not being empty.  Is there a way to rmove
> a directory and it's contents in python?
> Samuel P.

More information about the Python-list mailing list