Hi! First, thank you for komf — it's been very useful for managing large manga libraries.
Current behavior
When updateMode is set to COMIC_INFO, komf successfully writes metadata into the CBZ as ComicInfo.xml. However, when a cover thumbnail is fetched from a provider, it is only uploaded to Komga's internal thumbnail cache via the API (uploadBookThumbnail / uploadSeriesThumbnail). The image bytes are never written into the CBZ file itself.
This means the cover exists only in Komga's database, not in the actual file on disk.
Desired behavior
I'd like an option (e.g. embedCoverInCbz: true) where, in addition to uploading to Komga, the fetched thumbnail is also embedded into the CBZ archive as cover.jpg (or cover.png). This would make the cover truly portable — if the Komga library is scanned fresh, rebuilt, or migrated, the cover survives.
Why this matters for COMIC_INFO mode specifically
The whole point of COMIC_INFO mode seems to be making metadata self-contained in the file rather than only in the server's database. It feels natural to extend that philosophy to cover images as well.
Implementation sketch
Looking at the source, ComicInfoWriter already rewrites the ZIP in-place (creating a temp file and atomically replacing). Adding a writeCoverImage(localPath, image) method alongside writeMetadata() seems straightforward. MetadataUpdater.updateBookMetadata() could then call it when the new flag is set.
Questions
- Is there a reason this was intentionally left out? (e.g. file size concerns, format compatibility, Komga behavior)
- Would you be open to a PR implementing this as an opt-in option?
Thanks!
Hi! First, thank you for komf — it's been very useful for managing large manga libraries.
Current behavior
When
updateModeis set toCOMIC_INFO, komf successfully writes metadata into the CBZ asComicInfo.xml. However, when a cover thumbnail is fetched from a provider, it is only uploaded to Komga's internal thumbnail cache via the API (uploadBookThumbnail/uploadSeriesThumbnail). The image bytes are never written into the CBZ file itself.This means the cover exists only in Komga's database, not in the actual file on disk.
Desired behavior
I'd like an option (e.g.
embedCoverInCbz: true) where, in addition to uploading to Komga, the fetched thumbnail is also embedded into the CBZ archive ascover.jpg(orcover.png). This would make the cover truly portable — if the Komga library is scanned fresh, rebuilt, or migrated, the cover survives.Why this matters for
COMIC_INFOmode specificallyThe whole point of
COMIC_INFOmode seems to be making metadata self-contained in the file rather than only in the server's database. It feels natural to extend that philosophy to cover images as well.Implementation sketch
Looking at the source,
ComicInfoWriteralready rewrites the ZIP in-place (creating a temp file and atomically replacing). Adding awriteCoverImage(localPath, image)method alongsidewriteMetadata()seems straightforward.MetadataUpdater.updateBookMetadata()could then call it when the new flag is set.Questions
Thanks!