To use this template, you need:
pandoc
and pandoc-crossref
(must match in version)Run the script for the output format you want to build. For example:
./compile_pdf.sh
This will create a PDF file in the build
directory.
If you want to publish your ebook on Kindle, use kindlegen to convert epub
to mobi
.
./kindlegen ./build/epub/output.epub
pandoc-markdown-book/ # Root directory.
|- build/ # Folder used to store output files.
|- src/ # Markdowns files. Each chapter is stored in one folder.
| |- chapter-01 # Chapter 1
| | |- 00-title.md # Chapter title
| | |- 01-adessent in.md # First article of chapter 1
| | |- ...
| |- ...
|- img/ # Images folder.
| |- book-cover.pdf # Cover page for PDF.
| |- book-cover.png # Cover page for EPUB.
|- templates/ # Templates folder.
| |- eisvogel.latex # Template for PDF.
| |- epub.css # CSS for EPUB.
|- backgrounds/ # Backgrounds folder.
| |- background10.pdf # Background for title page.
|- metadata.yml # Metadata content (title, author...).
|- compile_epub.sh # Script to compile EPUB.
|- compile_html.sh # Script to compile HTML.
|- compile_pdf.sh # Script to compile PDF.
pandoc
obviously supports LaTeX equations, only PDF is able to render them correctly. EPUB will not look good at all. HTML is okay, though not as good as PDF.This template is modified based on original work by Ryan Frazier.
Many thanks to the awesome Eisvogel pandoc LaTeX template.