How can I delete the contents of a local folder in Python?
The current project is for Windows, but I would like to see *nix also.
I used to solve the problem this way:
import shutil import os shutil.rmtree(dirpath) os.mkdir(dirpath)