[Python] Removing a non-empty folder
摘要:
Removing a non-empty folderYou will get an ‘access is denied’ error when you attempt to use1 os.remove(“/folder_name”)to delete a folder which is not empty. The most direct and efficient way to remove non-empty folder is like this:1 import shutil2 shutil.rmtree(“/folder_name”)Of course you have othe 阅读全文
posted @ 2013-07-17 19:29 Hjärtat 阅读(473) 评论(0) 推荐(1) 编辑