comicfn2dict

An API and CLI for extracting structured comic metadata from filenames.

πŸ“œ News

comicfn2dict has a NEWS file to summarize changes that affect users.

πŸ•ΈοΈ HTML Docs

HTML formatted docs are available here

πŸ“¦ Install

pip install comicfn2dict

πŸ› οΈ API

from comicfn2dict import comicfn2dict, dict2comicfn

path = "Comic Series #001 Title (2024).cbz"

metadata: dict[str, str| tuple[str,...]] = comicfn2dict(path, verbose=0)

filename: str = dict2comicfn(metadata, bool=True, verbose=0)

There is also some autogenerated api docs attached to this documentation, but the codebase is small and probably easy to read.

⌨️ CLI

comicfn2dict "Series Name #01 - Title (2023).cbz"
{'ext': 'cbz',
'issue': '001',
'series': 'Series Name',
'title': 'Title',
'year': '2023'}

πŸ›  Development

comicfn2dict code is hosted at Github