SkillAgentSearch skills...

Mangal

📖 The most advanced (yet simple) cli manga downloader in the entire universe! Lua scrapers, export formats, anilist integration, fancy TUI and more!

Install / Use

/learn @metafates/Mangal

README

<h1 align="center"> <strong>Mangal 4 ☄️</strong> </h1> <p align="center"> <img alt="Linux" src="https://img.shields.io/badge/Linux-FCC624?style=for-the-badge&logo=linux&logoColor=black"> <img alt="macOS" src="https://img.shields.io/badge/mac%20os-000000?style=for-the-badge&logo=macos&logoColor=F0F0F0"> <img alt="Windows" src="https://img.shields.io/badge/Windows-0078D6?style=for-the-badge&logo=windows&logoColor=white"> <img alt="Termux" src="https://img.shields.io/badge/Termux-000000?style=for-the-badge&logo=GNOME%20Terminal&logoColor=white"> </p> <h3 align="center"> The most advanced CLI manga downloader in the entire universe! </h3> <p align="center"> <img alt="Mangal 4 TUI" src="assets/tui.gif"> </p>

[!CAUTION] As of April 2025, Mangal is no longer maintained. I am incredibly grateful to everyone who used it, contributed, or gave feedback along the way - thank you! Unfortunately, I just don't have the time to keep it going right now. That said, it's open source, so you're more than welcome to fork it, build on it, or maintain your own version. I might return to it someday, but for now, I don't recommend using it as-is - running unmaintained software can introduce security risks.

Try it!

curl -sSL mangal.metafates.one/run | sh

Note This script does not install anything, it just downloads, verifies and runs Mangal. Not available on Windows.

Table of contents

Features

  • Lua Scrapers!!! You can add any source you want by creating your own (or using someone's else) scraper with Lua 5.1. See mangal-scrapers repository
  • 4 Built-in sources - Mangadex, Manganelo, Manganato & Mangapill
  • Download & Read Manga - I mean, it would be strange if you couldn't, right?
  • Caching - Mangal will cache as much data as possible, so you don't have to wait for it to download the same data over and over again.
  • 4 Different export formats - PDF, CBZ, ZIP and plain images
  • TUI ✨ - You already know how to use it! (ノ>ω<)ノ :。・::・゚’★,。・:・゚’☆
  • Scriptable - You can use Mangal in your scripts, it's just a CLI app after all. Examples
  • History - Resume your reading from where you left off!
  • Fast? - YES.
  • Monolith - ZERO runtime dependencies. Even Lua is built in. Easy to install and use.
  • Cross-Platform - Linux, macOS, Windows, Termux, even your toaster. (¬‿¬ )
  • Anilist integration - Mangal will collect additional data from Anilist and use it to improve your reading experience. It can also sync your progress!

Installation

Script (Linux, MacOS, Termux)

Install using this shell script

curl -sSL mangal.metafates.one/install | sh

This script will automatically detect OS & Distro and use the best option available. For example, on macOS it will try to use Homebrew, on Ubuntu it will install the .deb package and so on...

Arch Linux

AUR package (maintained by @balajsra, thank you)

MacOS

Install using Homebrew

brew tap metafates/mangal
brew install mangal

Windows

Install using Scoop (thanks to @SonaliBendre for adding it to the official bucket)

scoop bucket add extras
scoop install mangal

Termux

Thanks to @T-Dynamos for adding it to the termux-packages

pkg install mangal

Gentoo

Install using third-party overlay raiagent. Thanks to @leycec for maintaining it.

eselect repository enable raiagent
emerge --sync raiagent
emerge mangal

Nix

Install using Nix. Thanks to @bertof for adding it to the nixpkgs

# NixOS
nix-env -iA nixos.mangal

# Non NixOS
nix-env -iA nixpkgs.mangal

Docker

Install using Docker. (thanks to @ArabCoders for reference)

docker pull metafates/mangal

To run

docker run --rm -ti -e "TERM=xterm-256color" -v $(PWD)/mangal/downloads:/downloads -v $(PWD)/mangal/config:/config metafates/mangal

From source

Visit this link to install Go.

Clone the repo

git clone --depth 1 https://github.com/metafates/mangal.git
cd mangal

GNU Make (Recommended)

make install # if you want to compile and install mangal to path
make build # if you want to just build the binary
<details> <summary>If you don't have GNU Make use this</summary>
# To build
go build -ldflags "-X 'github.com/metafates/mangal/constant.BuiltAt=$(date -u)' -X 'github.com/metafates/mangal/constant.BuiltBy=$(whoami)' -X 'github.com/metafates/mangal/constant.Revision=$(git rev-parse --short HEAD)' -s -w"

# To install
go install -ldflags "-X 'github.com/metafates/mangal/constant.BuiltAt=$(date -u)' -X 'github.com/metafates/mangal/constant.BuiltBy=$(whoami)' -X 'github.com/metafates/mangal/constant.Revision=$(git rev-parse --short HEAD)' -s -w"
</details>

If you want to build mangal for other architecture, say ARM, you'll have to set env variables GOOS and GOARCH

GOOS=linux GOARCH=arm64 make build

Available GOOS and GOARCH combinations

Pre-compiled

Download the pre-compiled binaries from the releases page and copy them to the desired location.

Usage

TUI

Just run mangal and you're ready to go.

<details> <summary>Keybinds</summary>

| Bind | Description | |-------------------------------------------------------------|--------------------------------------| | <kbd>?</kbd> | Show help | | <kbd>↑/j</kbd> <kbd>↓/k</kbd> <kbd>→/l</kbd> <kbd>←/h</kbd> | Navigate | | <kbd>g</kbd> | Go to first | | <kbd>G</kbd> | Go to last | | <kbd>/</kbd> | Filter | | <kbd>esc</kbd> | Back | | <kbd>space</kbd> | Select one | | <kbd>tab</kbd> | Select all | | <kbd>v</kbd> | Select volume | | <kbd>backspace</kbd> | Unselect all | | <kbd>enter</kbd> | Confirm | | <kbd>o</kbd> | Open URL | | <kbd>r</kbd> | Read | | <kbd>q</kbd> | Quit | | <kbd>ctrl+c</kbd> | Force quit | | <kbd>a</kbd> | Select Anilist manga (chapters list) | | <kbd>d</kbd> | Delete single history entry |

</details>

TUI

If you wonder what those icons mean - D stands for "downloaded", * shows that chapter is marked to be downloaded. You can choose different icons, e.g. nerd font ones - just run mangal with --icons nerd. Available options are nerd, emoji, kaomoji and squares

Mini

Mini mode tries to mimic ani-cli

To run: mangal mini

mini

Inline

Inline mode is intended for use with other scripts.

Type mangal help inline for more information.

See Wiki for more examples.

<p align="center"> <img alt="Mangal 4 Inline" src="assets/inline.gif"> </p>

Other

See mangal help for more information

Configuration

Mangal uses TOML format for configuration under the mangal.toml filename. Config path depends on the OS. To find yours, use mangal where --config. For example, on Linux it would be ~/.config/mangal/mangal.toml.

Use env variable MANGAL_CONFIG_PATH to set custom config path.

See mangal env to show all available env variables.

| Command | Description | |-----------------------|--------------------------------------------------| | mangal config get | Get config value for specific key | | mangal config set | Set config value for specific key | | mangal config reset | Reset config value for specific key | | mangal config info

Related Skills

View on GitHub
GitHub Stars1.7k
CategoryDevelopment
Updated1d ago
Forks85

Languages

Go

Security Score

100/100

Audited on Mar 29, 2026

No findings