Find directories that DON'T contain a file

Posted by Oli on Ask Ubuntu See other posts from Ask Ubuntu or by Oli
Published on 2012-10-05T23:27:52Z Indexed on 2012/10/10 9:52 UTC
Read the original article Hit count: 223

Filed under:
|

Yes, I'm sorting out my music. I've got everything arranged beautifully in the following mantra: /Artist/Album/Track - Artist - Title.ext and if one exists, the cover sits in /Artist/Album/cover.(jpg|png).

I want to scan through all the second-level directories and find the ones that don't have a cover. By second level, I mean I don't care if /Britney Spears/ doesn't have a cover.jpg, but I would care if /Britney Spears/In The Zone/ didn't have one.

Don't worry about the cover-downloading (that's a fun project for me tomorrow) I only care about the glorious bash-fuiness about an inverse-ish find example.

© Ask Ubuntu or respective owner

Related posts about bash

Related posts about find