我想使用 bat 文件删除包含所有文件和子文件夹的文件夹。
我尝试了以下方法,但它不起作用:
@DEL D:\PHP_Projects\testproject\Release\testfolder*.*
有人可以帮忙吗?
@RD /S /Q "D:\PHP_Projects\testproject\Release\testfolder"
说明:
移除(删除)一个目录。 RMDIR [/S] [/Q] [drive:]path RD [/S] [/Q] [drive:]path /S Removes all directories and files in the specified directory in addition to the directory itself. Used to remove a directory tree. /Q Quiet mode, do not ask if ok to remove a directory tree with /S
移除(删除)一个目录。
RMDIR [/S] [/Q] [drive:]path RD [/S] [/Q] [drive:]path /S Removes all directories and files in the specified directory in addition to the directory itself. Used to remove a directory tree. /Q Quiet mode, do not ask if ok to remove a directory tree with /S