Skip to main content

CLI to search and download manga chapters -> exported to CBZ.

Project description

KizamuManga

๐Ÿ“š KizamuManga State License

KizamuManga is a command-line tool to search, download, and convert manga chapters into CBZ files from different online sources.

โœจ Main Features

  • ๐Ÿ”Ž Interactive search for manga and chapter selection directly from the terminal.
  • โšก Asynchronous downloads with concurrency control, automatic CBZ export, and cleanup of temporary files.
  • ๐Ÿ–ผ๏ธ Optional image processing: grayscale conversion, margin cropping, and proportional resizing.
  • ๐ŸŒ Multi-source support (WeebCentral, InManga, and LeerMangaEsp) with an extensible scraping system based on Playwright.
  • ๐Ÿ“Š Progress indicators and rotating logs for easy tracking of execution.

โšก Quick Start

  1. Install the program package via pip
pip install kizamu-manga
  1. Install the playwright browsers
playwright install
  1. start searching or installing a manga
kizamumanga search "One Piece"
kizamumanga install "One Piece"

๐Ÿงพ Requirements

  • Python 3.9 or higher.
  • Dependencies listed in requirements.txt.
  • Playwright installed along with its browsers (playwright install).
  • Access to the supported websites to fetch online chapters.

โš™๏ธ Installation

Option 1: Install from PyPI (recommended)

If you just want to use the tool:

pip install kizamu-manga
playwright install

Option 2: Install from source

# Clone the repository
git clone https://github.com/<your-user>/kizamu-manga.git
cd kizamu-manga

# (Optional) Create and activate a virtual environment
python -m venv .venv
source .venv/bin/activate   # Linux/Mac
.venv\Scripts\activate      # Windows

# Install dependencies
pip install -r requirements.txt

# Install Playwright browsers
playwright install

๐Ÿ”ง Configuration

The config.toml file (at the project root) allows customization of parameters such as:

Key Description
cbz_path Destination folder for CBZ files (default: Documents/manga_downloads).
website Active source (weeb_central -> stable, inmanga-> unstable, leermangaesp) -> stable
multiple_tasks Maximum number of concurrent downloads.
color Export in color (true) or grayscale (false).
cropping_mode Enable automatic margin cropping.
width / height Target resolution; leave empty to keep original size.

You can also modify configuration directly from the terminal. Here are some common use cases:

Change scraper source and concurrency:

  kizamumanga config scraper --website "inmanga" --multiple_tasks 5
  • This switches the active scraper to inmanga and sets the maximum number of parallel download tasks to 5.

Change output folder for CBZ files:

  kizamumanga config paths --cbz_path "./my_manga"
  • This updates the destination directory where downloaded CBZ files are stored.

Apply a predefined resolution profile:

Currently supported device presets: boox_go_7 (more coming soon).

  kizamumanga config dimensions --device "boox_go_7"
  • This automatically assigns width/height settings based on the Boox Go 7 device preset.

Manually set output resolution:

  kizamumanga config dimensions --width 1080 --height 1440
  • This forces a custom resolution (1080ร—1440 px), overriding any preset device profile.

Export in grayscale with margin cropping enabled:

  kizamumanga config output --color false --cropping_mode true
  • This configures exported images to be grayscale and have automatic margin cropping applied.

๐Ÿ•น๏ธ Basic Usage

  • Search for manga: kizamumanga search "One Piece"
  • Download all chapters: kizamumanga install "One Piece"
  • Download a specific chapter or range:
    • kizamumanga install "One Piece" 5
    • kizamumanga install "One Piece" 10-15

By default CBZ files are saved in:

  • Linux/Mac: $HOME/Documents/manga_downloads
  • Windows: %USERPROFILE%\Documents\manga_downloads

You can change the location by using kizamumanga config paths --cbz_path "./my_manga".

๐Ÿ”„ Internal Workflow

  1. The Runner validates arguments, loads configuration, and sets up the selected scraper.
  2. Manga and chapter lists are fetched using Playwright + BeautifulSoup.
  3. Each chapter is downloaded via aiohttp, optionally processed, and packed into a CBZ.

๐Ÿ—‚๏ธ Project Structure

โ”œโ”€โ”€ config.toml
โ”œโ”€โ”€ pyproject.toml
โ”œโ”€โ”€ requirements.txt
โ””โ”€โ”€ src/
    โ””โ”€โ”€ kizamumanga/
        โ”œโ”€โ”€ main.py
        โ”œโ”€โ”€ handlers/
        โ”‚   โ””โ”€โ”€ args_handler.py
        โ”œโ”€โ”€ engine/
        โ”‚   โ”œโ”€โ”€ runner.py
        โ”‚   โ”œโ”€โ”€ downloader.py
        โ”‚   โ”œโ”€โ”€ image_converter.py
        โ”‚   โ””โ”€โ”€ paths.py
        โ”œโ”€โ”€ scraping/
        โ”‚   โ”œโ”€โ”€ base.py
        โ”‚   โ”œโ”€โ”€ weeb_central.py
        โ”‚   โ”œโ”€โ”€ inmanga.py
        โ”‚   โ””โ”€โ”€ leermangaesp.py
        โ””โ”€โ”€ utils/
            โ”œโ”€โ”€ logger.py
            โ”œโ”€โ”€ loading_spinner.py
            โ””โ”€โ”€ general_tools.py

๐Ÿ“œ License

This project is under the license MIT.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

kizamu_manga-1.0.1.tar.gz (21.2 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

kizamu_manga-1.0.1-py3-none-any.whl (29.4 kB view details)

Uploaded Python 3

File details

Details for the file kizamu_manga-1.0.1.tar.gz.

File metadata

  • Download URL: kizamu_manga-1.0.1.tar.gz
  • Upload date:
  • Size: 21.2 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.13.7

File hashes

Hashes for kizamu_manga-1.0.1.tar.gz
Algorithm Hash digest
SHA256 54e06a09bd53bdbdacaf80d9d649733d3199e6dfb3f3d1bdc128818bb867d249
MD5 b3a942bb9b50a78d700b04418b04d035
BLAKE2b-256 12972a5602f5e475d7ed307c4326ccaa57b568a06b3c55caba24a34dbaeadf4e

See more details on using hashes here.

File details

Details for the file kizamu_manga-1.0.1-py3-none-any.whl.

File metadata

  • Download URL: kizamu_manga-1.0.1-py3-none-any.whl
  • Upload date:
  • Size: 29.4 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.13.7

File hashes

Hashes for kizamu_manga-1.0.1-py3-none-any.whl
Algorithm Hash digest
SHA256 8fb2234118d71c06c1b09521dcbe53b8be34c43d579d0fc9a95a98636eea32bf
MD5 e8f2263d8416458c2e67aef8cf4e6462
BLAKE2b-256 f0d3270e67a528f6d978fb6314393ee3b291a736707f0d4aff9a87fa193c9509

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page