in reply to Re: Win32: Deleting Temporary directories of all users on a machine?
in thread Win32: Deleting Temporary directories of all users on a machine (recursive)?

Hm. Is there a reason i should not use the rmdir http://perldoc.perl.org/functions/rmdir.html command I am on windows so i maybe could use something like
"del /s /q *.*"

Thanks
MH
  • Comment on Re^2: Win32: Deleting Temporary directories of all users on a machine?

Replies are listed 'Best First'.
Re^3: Win32: Deleting Temporary directories of all users on a machine?
by BrowserUk (Patriarch) on Jan 13, 2010 at 08:32 UTC

    The built-in rmdir function will only remove a directory if it is empty.

    del /s descends directories deleting the files, but leaves empty subdirectories in place.

    rd /s gets shot of everything (assuming permission).


    Examine what is said, not who speaks -- Silence betokens consent -- Love the truth but pardon error.
    "Science is about questioning the status quo. Questioning authority".
    In the absence of evidence, opinion is indistinguishable from prejudice.