deleting directory tree

Daniel Dittmar daniel.dittmar at sap.com
Wed Nov 21 04:31:15 EST 2001


> Can someone explain what os.removedirs() does? I needed a function to
remove
> a directory and all its files and subdirectories, and ended up writing
one.
> It seems that there should be such a function in os, but I drew a blank.

Use shutil.rmtree ().

Daniel






More information about the Python-list mailing list