Skip to content

Conversation

@timusus
Copy link
Owner

@timusus timusus commented Nov 16, 2025

Fixes #169

The regex pattern for detecting album art files has been expanded to include common filename variations that were previously not recognized:

  • albumart.jpg/png (iTunes/Windows Media Player standard)
  • front.jpg/png (front cover artwork)
  • artwork.jpg/png (generic artwork files)

These additions complement the existing patterns (folder, cover, album) and maintain support for hidden files (those starting with a dot).

The pattern now matches:

  • folder.jpg, cover.jpg, album.jpg (existing)
  • albumart.jpg, albumartsmall.jpg (new)
  • front.jpg, frontcover.jpg (new)
  • artwork.jpg (new)
  • All with optional leading dot for hidden files

Fixes #169

The regex pattern for detecting album art files has been expanded to
include common filename variations that were previously not recognized:
- albumart.jpg/png (iTunes/Windows Media Player standard)
- front.jpg/png (front cover artwork)
- artwork.jpg/png (generic artwork files)

These additions complement the existing patterns (folder, cover, album)
and maintain support for hidden files (those starting with a dot).

The pattern now matches:
- folder.jpg, cover.jpg, album.jpg (existing)
- albumart.jpg, albumartsmall.jpg (new)
- front.jpg, frontcover.jpg (new)
- artwork.jpg (new)
- All with optional leading dot for hidden files
@timusus timusus changed the title Investigate and propose solution for issue Folder based artwork naming improvements Nov 16, 2025
@rivaldi8
Copy link
Contributor

rivaldi8 commented Jan 6, 2026

I had a look to the changes the other day and saw some room for improvement, so I've gone ahead and done some improvements:

  • Ensure the input stream is closed after use.
  • Extract the common code.
  • Fallback to any image found in the directory if none is found with a standard name. Because, as much as we'd like artwork files to be properly named, the reality is that a lot of times they'll have some other name. For example, a quick search in my library has found images named with several variations of the expected ones, the name of the album, UUIDs, and lots of weird names.

I've pushed the changes to the branch alexm-improve-artowork-detection (rebased to main), if you want to cherry-pick them. Or I can open a separate pull request, if you prefer.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Album art does not appear to work consistently

4 participants