Coder Social home page Coder Social logo

pandoc-ebook-template's Introduction

Pandoc Markdown ebook template

Forked from Source on 2023-08-24.

This project defines a skeleton repo for creating ebooks out of Pandoc Markdown. Pandoc is a great tool for writing ebooks with simple to moderately complex formatting, but I've found that in practice, creating an EPUB isn't quite as simple as just running pandoc -o book.epub book.md.

The author of Pandoc has written a short tutorial for creating EPUB files with Pandoc. This repo just expands on MacFarlane's tutorial a bit and wraps things up in a Makefile.

Installing and running

  1. If you have not already done so, install:
  2. Clone this repo with git.
  3. From the top of the project, type make book or simply, make. This generates three versions of the sample book in a build/ directory.

Replacing the sample material

Edit these files:

ch01.md and ch02.md

Replace the dummy text with your own. You can add, subtract, or rename these *.md chapters as you please, but you must edit the CHAPTERS variable in the Makefile accordingly.

images/cover.jpg

Replace this with your own cover image or delete it entirely.

Makefile

  • Change BOOKNAME to something appropriate for your book. This determines your book's filename.

  • Change CHAPTERS to a space separated list of Pandoc Markdown chapters, in the order in which you want them to appear.

  • Change COVER_IMAGE. You might want to move your cover image elsewhere, or use a different file format such as PNG.

    If you don't want a cover image, delete this variable and the --epub-cover-image option in the EPUB target.

  • (Optional) Change LATEX_CLASS. The default of report handles multi-chapter books pretty well, and uses the same template for even and odd page numbers. However, you are free to substitute in any other LaTeX document class. For example, book provides a left-side/right-side template that is suitable for print, and article is good for shorter manuscripts (short stories, technical briefs).

title.txt

Replace the contents of this file with the real manuscript title and author name.

metadata.xml

Replace with your actual copyright statement, language, and any other Dublin Core metadata you wish to provide.

pandoc-ebook-template's People

Contributors

btbytes avatar evangoer avatar

Watchers

 avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.