I want this script to display all folders containing "deleted" in the folder name, but not if they are in the "done" folder.
For example: specify the folder if it is in C:\temp, and if it is in C:\temp\random_folder_name, but not if it is inC:\temp\done
dir /s "C:\temp" | findstr "\deleted"
exclude all folders with the name "done" and their contents.
Tomas source
share