/p when used with DEL

ron

Aug 19, 2008
151
0
del /p /s /x /a:d f:\test\*.*

Was testing a command to remove all the empty folders in a path. Had a question about /p. I was expecting a prompt but didn't get one. It did remove all the empty folders and left files alone though. Just curious what the expectation should be using /p.
 
DEL /P prompts before deleting each file. If you also specify /A:D, no files will match, so you won't get any prompts. /P also overrides the default prompt you get when you specify a wildspec of * or equivalent.
 
  • Like
Reactions: ron

Similar threads