Recursivley delete a specific file in windows

Problem

I had WS_FTP.log in almost all my folders. I didn’t want them anymore so I needed a way to easily recursively delete the file from all my sub directories.

Solution

Open the dos prompt (cmd). navigate to the directory that you want to remove the files in. Run the following command to get rid of any file ending in .tmp
del /s *.tmp

Be careful with using this. It will delete all files that you specify under the directory you are located in.

source: http://www.tech-recipes.com/rx/184/recursively-delete-files-in-windows/

Tagged with:

Leave a Reply

Your email address will not be published. Required fields are marked *

*