Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/OpenBookPublishers/epublius
Generates a stylised HTML site from an ePub book
https://github.com/OpenBookPublishers/epublius
Last synced: about 2 months ago
JSON representation
Generates a stylised HTML site from an ePub book
- Host: GitHub
- URL: https://github.com/OpenBookPublishers/epublius
- Owner: OpenBookPublishers
- License: gpl-3.0
- Created: 2016-06-25T04:53:35.000Z (over 8 years ago)
- Default Branch: master
- Last Pushed: 2024-07-24T09:48:53.000Z (5 months ago)
- Last Synced: 2024-08-04T13:06:51.201Z (5 months ago)
- Language: Python
- Size: 580 KB
- Stars: 28
- Watchers: 2
- Forks: 4
- Open Issues: 8
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# epublius
A tool to generate a standalone website from an EPUB.
## Usage
The entry point is `.src/main.py`, which can be called with the following arguments:
| Parameter | Description |
|-----------|---------------------------------------------------------------------------|
| `-b` | URL of book's page |
| `-t` | TOC file |
| `-f` | Frontpage file |
| `-d` | Directory prefix (of content, not prefix/suffix) |
| `-o` | Target directory |
| `-h` | File containing HTML to inject into header |
| `-n` | Title name |
| `-c` | A colophon file (e.g., the license). There may be multiple -c parameters |
| `-r` | How much to resize the images (as percentage; default is 50). |
| `-u` | URL path of this book |
| `-k` | Copyright file |
| `-a` | Donation link |
| `-m` | MathJax support |
| `-p` | Privacy policy URL |
| `-w` | Write chapter URLs to Thoth (True/False) |## Thoth Wrapper (Optional)
### Installation
Clone the repo and build the image with $ `docker build . -t openbookpublishers/epublius`.
### Usage
```bash
docker run --rm \
-v /path/to/local.epub:/ebook_automation/epub_file.epub \
-v /path/to/output:/ebook_automation/output \
-e MATHJAX=False \
-e PRIVACYPOLICY_URL=https://example.org \
-e [email protected] \
-e THOTH_PWD=password \
openbookpublishers/epublius \
thoth_wrapper.py /ebook_automation/epub_file.epub \
--doi 10.11647/obp.0275
```The environment variable MATHJAX enables or disable MathJax support
The environment variables THOTH_EMAIL and THOTH_PWD allow use of the `--write-urls` option by providing Thoth credentials## Contributing
Pull requests are welcome.
## License
[GPLv3](https://www.gnu.org/licenses/gpl-3.0.en.html)