txt2ebook
A console tool to convert txt file to different ebook formats.
Installation
Stable version From PyPI:
uv tool install txt2ebook
Upgrade to latest stable version:
uv tool upgrade txt2ebook
Add autocompletion to your Bash config:
eval "$(register-python-argcomplete tte)"
eval "$(register-python-argcomplete txt2ebook)"
Usage
Showing help message of command-line options:
txt2ebook --help
usage: txt2ebook [-of OUTPUT_FOLDER] [-p] [-y] [-rw] [-q] [-v]
[-d] [-h] [-V]
{env,epub,gmi,massage,md,parse,pdf,tex,typ} ...
txt2ebook/tte is a cli tool to convert txt file to ebook format.
website: https://github.com/kianmeng/txt2ebook
changelog: https://github.com/kianmeng/txt2ebook/blob/master/CHANGELOG.md
issues: https://github.com/kianmeng/txt2ebook/issues
positional arguments:
{env,epub,gmi,massage,md,parse,pdf,tex,typ}
sub-command help
env
print environment information for bug reporting
epub
generate ebook in EPUB format
gmi
generate ebook in Gemtext format
massage
massage the source txt file
md
generate ebook in Markdown format
parse
parse and validate the txt file
pdf
generate ebook in PDF format
tex
generate ebook in TeX/PDF format
typ
generate ebook in Typst format
options:
-of, --output-folder OUTPUT_FOLDER
set default output folder (default: 'output')
-p, --purge
remove converted ebooks specified by --output-folder option (default: 'False')
-y, --yes
assume yes to all prompts (default: 'False')
-rw, --raise-on-warning
raise exception and stop parsing upon warning
-q, --quiet
suppress all logging
-v, --verbose
show verbosity of debugging log, use -vv, -vvv for more details
-d, --debug
show debugging log and stacktrace
-h, --help
show this help message and exit
-V, --version
show program's version number and exit
Convert a txt file into epub:
txt2ebook ebook.txt
Copyright and License
Copyright (c) 2021,2022,2023,2024,2025,2026 Kian-Meng Ang
This program is free software: you can redistribute it and/or modify it under the terms of the GNU Affero General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version.
This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Affero General Public License for more details.
You should have received a copy of the GNU Affero General Public License along with this program. If not, see https://www.gnu.org/licenses/.
The fish logo used in the documentation generated by Sphinx is a public domain drawing of Troschel's parrotfish (Chlorurus troschelii Var. A.) from https://commons.wikimedia.org/entity/M18506436. 18506436>.
Metadata
Release files for txt2ebook 0.1.214
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| txt2ebook-0.1.214.tar.gz | 46.4 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| txt2ebook-0.1.214-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 119.3 kB
Release files / txt2ebook-0.1.214.tar.gz
| Download URL | txt2ebook-0.1.214.tar.gz |
|---|---|
| Size | 46.4 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
f8005cb6f9cb40a4fe65f9c3712b67c6169af97d9db7e936e74cd15366713374
|
|
BLAKE2b-256 checksum How to use checksums |
c9718b4126f68e8d701be343990f1003793c8a47d512daf0b43bebcdd42b569b
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
uv/0.12.23 {"installer":{"name":"uv","version":"0.12.23","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"26.04","id":"resolute","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}
|
Release files / txt2ebook-0.1.214-py3-none-any.whl
| Download URL | txt2ebook-0.1.214-py3-none-any.whl |
|---|---|
| Size | 72.9 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
ca8824eb8c9600a6c83646b44dd7dbb750b6b47121f5786a8bf749ccebfa7473
|
|
BLAKE2b-256 checksum How to use checksums |
dd515d672060d4df820ea57e321fa9c6dcd14fe00494ba38bf9fe3618f84a6ce
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
uv/0.12.23 {"installer":{"name":"uv","version":"0.12.23","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"26.04","id":"resolute","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}
|