Parse common comic filenames and return a dict of metadata attributes. Includes a cli.
Project description
comicfn2dict
An API and CLI for extracting structured comic metadata from filenames.
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)
CLI
comicfn2dict "Series Name #01 - Title (2023).cbz"
{'ext': 'cbz',
'issue': '001',
'series': 'Series Name',
'title': 'Title',
'year': '2023'}
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
comicfn2dict-0.2.1.tar.gz
(26.3 kB
view details)
Built Distribution
File details
Details for the file comicfn2dict-0.2.1.tar.gz
.
File metadata
- Download URL: comicfn2dict-0.2.1.tar.gz
- Upload date:
- Size: 26.3 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: poetry/1.8.2 CPython/3.12.1 Linux/5.15.0-1053-aws
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 0e0933d7decc043cad61f8724417c8e28e0e086892a7fb730886f6cfcb7f2b4d |
|
MD5 | 077afacc49280d10726f21f6c495d02e |
|
BLAKE2b-256 | ed05f7bc00d617d187fb1a511010958e0af0976bdd016d123b574eb9a8ff5001 |
File details
Details for the file comicfn2dict-0.2.1-py3-none-any.whl
.
File metadata
- Download URL: comicfn2dict-0.2.1-py3-none-any.whl
- Upload date:
- Size: 22.8 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: poetry/1.8.2 CPython/3.12.1 Linux/5.15.0-1053-aws
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 738eb7b9c61f3be8fb875662195e1d7231fbd21a27d2c71f95da96a9198abdc6 |
|
MD5 | 726198bfc93f956815ce0fc5d310386e |
|
BLAKE2b-256 | 5c2a76b70845f50dfd8d2b9e1f94c326cabe5fed5545cc55ba13c4c53609b775 |