Hi, I'm using Banshee on Linux and I have it auto-organize my music collection in folder hierarchies. When I add a new album to my Music folder, Banshee automatically moves (and renames) the mp3s and puts them into the correct Artist folder. If there is no other file in the folder, then the folder is also deleted, but if other files are present, only the mp3s are moved and the folder remains. Because of this, I have a number of folders inside my music folder that contain no mp3s, only an image file or similar ancillary file.
How would I go about removing any folder (inside the Music folder) that does not have an mp3 file inside?
For example, suppose I have the following:
/home/user/Music/
and I add the folder "Album 1 (2010)" which has mp3s and also cover art. Banshee will pull out the mp3s and put them in the proper artist folder, say:
/home/user/Music/Artist
but then the folder
/home/user/Music/Album 1 (2010)
still exists. How can I check if this folder has an mp3 in it, and if not, delete it?
I figure the answer will be a command line one, but I'm open to any suggestion. Also, it might be good to require a confirmation...just in case.
Thanks!