

The meta-information follows a similar pattern: each output format has its own meta-information file.

You can put more than one chapter in each file, but putting them in separate files makes it easier to find content and do updates later. Declare chapters using the Markdown heading H1 ( #). My books follow the one-chapter-per-file pattern. You can also use HTML, but the more HTML you introduce the highest risk that problems arise when Pandoc converts Markdown to an ePub document. I do all of my writing in Markdown syntax. You can find the code in my Programming Fight Club GitHub repository. Finally, I demonstrate how to generate its companion ePub book. I'll use my upcoming e-book, GRASP Principles for the Object-Oriented Mind, which I created using this process, as an example.įirst I will explain the file structure used for the book, then how to use Pandoc to generate a website and deploy it in GitHub. In this follow-up article, I'll dive deeper into Pandoc, showing how to produce a website and an ePub book from the same Markdown source file. In my introduction to Pandoc, I explained how to convert text written in Markdown into a website, a slideshow, and a PDF. Pandoc is a command-line tool for converting files from one markup language to another.
