Filed under: Utilities, Windows, Microsoft, Freeware, How-Tos
Automatically delete empty subdirectories with one-line batch file
Deleting empty subdirectories seems like something Windows ought to do automatically, but for some reason that function just isn't included as part of the OS. Luckily, you don't need to download a utility to do it; instead, you can create a single line batch file that will do exactly what you're looking for:
for /f "usebackq" %%d in ("dir /ad/b/s | sort /R") do rd "%%d"
Raymond Chen, the venerable Microsoft coder, explains how this works. Basically, it uses a trick to enumerate the directories in reverse order. Since you can't delete a directory that contains data (including other directories) the only way to automate deleting directories is to start at the very bottom of the tree and work your way up.




Should we really trust a guy named Jackass JoeJoe? Well I did, and was amply rewarded. Anyone working with digital media assets for one reason or another winds up with gaggles of files. Renaming those, or changing anything en masse is a total chore. Thus, we have a slew of renaming utilities out there. I tried
So, just how good at time waster games are you? Think you've got the stuff? Well, The World's Hardest Game 2.0 doesn't think you do.
Yes, amazingly, it's possible to have a sequel to a game called "The World's Hardest Game". It doesn't seem logically possible, since if the first one was actually the world's hardest, how could another one come along and share the moniker? It made me doubt the name in the first place. That is, until I tried the game.
The mechanics of the game are very simple. You are a small red square, ...
