Repository
Current version released
10 months ago
md2epub
Convert a folder with markdown files to an epub book.
Install
Requires deno
deno install -n md2epub --allow-read --allow-write https://deno.land/x/md2epub/mod.tsUsage
md2epub <FOLDER>will convert all markdown files in <FOLDER> to an epub. Subfolders will become
sections. Pages will be in alphabetic order, name the files accordingly.
Example folder structure:
book
βββ 1. First part
βΒ Β  βββ 01-intro.md
βΒ Β  βββ 02-begin.md
βββ 2. Second part
βΒ Β  βββ 01-some-chapter.md
βΒ Β  βββ 02-the-end.md
βββ cover.jpg
βββ meta.yamlCommand:
md2epub bookMetadata
Metadata is set with a <FOLDER>/meta.yaml file with the following keys:
- author (string, default 
Unkown author) - filename (string, default a UUID)
 - language (string, default 
en-UK) - publisher (string, default 
Unknown publisher) - source (string, default 
Unkown source) - title (string, default 
Unknown title) - cover (string, no default)
 
Example:
author: Some author name
filename: my-book
language: en-US
publisher: Books Inc.
source: https://bo.oks
title: My book
cover: cover.jpg