CMD: How do I delete all the contents of all directories (in the current directory) without deleting the directories themselves?
- by merlin2011
For example:
I'm in the directory:
F:\Data
Inside this directory, I have four directories:
F:\Datadir
22179 22915 23459 23460
These directories have various content, including directories and files.
I'm trying to run something like:
rmdir /s *\*
where I delete all the contents of these numbered directories, while leaving the empty directories. Is there a one-liner that can do this, or do I have to loop through the sub-directories?