Recursively delete files in Windows

Contributor Icon Contributed by qmchenry Date Icon October 11, 2003  
Tag Icon Tagged: Windows

The del command allows recursive removal of specified files.


To delete all files ending in .tmp in the current directory and all subdirectories, use:

del /s *.tmp

Warning: Be certain you know exactly what you are doing before using the command. To be more careful, you can specify that the del command will prompt for confirmation before deleting each file:

del /s /p *.tmp

Previous recipe | Next recipe |
 

Viewing 2 Comments

 
close Reblog this comment
blog comments powered by Disqus