Archive for the 'Scripts / Code' Category

Removing Empty Sub-folders

(From Old Database) I was messing around with my music collection and found that I had many empty directories and sub-directories and wanted to get rid of them so that it wasn’t false excitement on certain bands. After days of searching, and trying to find a solution (without actually having to manually delete 2000+ directories manually) I found that simple commands help.

#find /path/to/dir -type d -exec rmdir {} \;

Just wanted to paste this so I wouldn’t forget it.