Markdown To Ebook
$7.99
Minimum price
$10.00
Suggested price

Markdown To Ebook

About the Book

This is a book on creating ebooks using Markdown. No esoteric and complicated formats. No WYSIWYG editors. No PDF hell. Just plaintext.

You'll learn the following;

  • The differences between various Markdown implementations
  • How to take Markdown and turn it into;
    • epub
    • mobi
    • pdf
    • html
  • How to work with code samples, codeblocks, images, TOC etc
  • How to build custom Markdown extensions using Kramdown. For stuff like;
    • code bubbles
    • notes
    • asides
    • and other nifty little doodads
  • How various html ebook format wrappers (such as ePub, mobi etc) work. No magic!
  • Common markdown pitfalls (I documented all my failures while writing this book)
  • Various techniques for previewing your Markdown output
    • Sublime Text Previewing
    • html previews
    • automatic previews using the guard gem
  • How to mirror the Leanpub workflow using local tools
  • How to customize converters so you have full control of your in-between formats; laTeX (pdf) and HTML (ePub, mobi etc)
  • The minimal laTeX you'll need to get stuff done with PDF

What you need to know

Some hacker skills are necessary to make full use of this book. To write books using Markdown you'll need to be comfortable getting your hands dirty, breaking things and learning. This book doesn't assume you're skilled in any particular language but it assumes you are skilled in programming. Familiarity with your systems package manager will be necessary.

Can you do this? $ homebrew install

Or if you are on Linux this? $ sudo apt-get install

If this leaves you scratching your head then you are not ready for this book. If you are left feeling comfortable and at ease, not queasy and fearful, then you are ready.

Some rudimentary ability to read and edit Ruby will also be necessary. If you are comfortable enough to edit Gemfiles and install gems using bundler then you should be fine.

Planned Chapters

Chapters on the following topics are planned;

  • Using Quarto and PDFKit to generate PDFs from XHTML + CSS
  • Web based books with runnable consoles and code samples

Will be updated continuously

The tools and techniques used to make ebooks change swiftly and often drastically. I intend to continue writing ebooks into the foreseeable future and will continue to update this book as I discover new things. Thus, this book will always mirror closely my current workflow for writing and publishing ebooks.

This book is currently in beta

It is still undergoing proofreading, editing and revision. The last 10% can make a big difference in the quality of a work so please be forgiving if it does not meet your expectations.

Pricing and Licensing

Licensed under a MIT license and open sourced on Github. This does not mean I don't want money for my efforts. I simply recognize that the more permissively licensed a work is the more valuable it becomes. The greater the freedom you have to use my words the more valuable they are to you. My goal is to make this book as valuable to you as possible.

Feel free to take my book and use it in whatever way you like, in whatever way furthers your life the most. Remix it, convert it, port it, share it, quote from it or even sell it. I only ask that in return, you give back to me what I gave to you. How much this book is worth to you is up to you to decide.

About the Author

K-2052
K-2052

I'm a developer, designer and occasional writer.

Table of Contents

  • An Introduction
    • What you need to know
  • We are going to need a workflow
    • Where will we distribute the book?
    • What final format does it need to be in when distributed?
    • LaTeX
    • Leanpub
  • Flavors of Markdown
    • Github flavored Markdown
    • MultiMarkdown
    • Markdown Extra
    • Learn your Markdown
  • Leanpubbin’: A Brief Introduction To Leanpub
    • Leanpub Markdown flavor
    • Previewing Leanpub locally
  • LaTeXing
    • Installing LaTeX
    • Installing LaTeX Packages on Mac
    • Installing LaTeX Packages on Ubuntu (and other Debians)
    • Using Packages
    • LaTeX: A Very Brief Introduction
    • Custom LaTeX Styles
  • Going Local
    • All the Markdown in One
    • Creating PDFs
    • Images and Your PDFs.
  • Common Customizations
    • My God, it’s full of Snippets
    • Including Source Files With Kramdown
    • Including Source Files With Pandoc
    • Including Files via LaTeX
    • Generating a Table of Contents
    • Custom thing a ma bobs.
    • A key binding awaits
  • Krambook: Build a Gem
  • A Sublime Markdown Experience
    • Count my chars, measure my words, tell me the lines, express my worth
    • Getting Sublime
  • All the features of Leanpub
    • Move Aside
    • Icons
    • Includes like Leanpub
    • Make the code blocks detect their language
    • Use pygments with Kramdown
  • Pitfalls
    • Markdown Issues
    • LaTeX to PDF
    • HTML, Epub, Mobi etc
  • Prepping for Publishing.
    • Converting to epub
    • From epub to mobi and beyond
    • Cover Images
    • Some brief notes on styling things
  • Wrap Up
    • Notes
    • The End

The Leanpub 60-day 100% Happiness Guarantee

Within 60 days of purchase you can get a 100% refund on any Leanpub purchase, in two clicks.

See full terms

Do Well. Do Good.

Authors have earned$11,948,857writing, publishing and selling on Leanpub, earning 80% royalties while saving up to 25 million pounds of CO2 and up to 46,000 trees.

Learn more about writing on Leanpub

Free Updates. DRM Free.

If you buy a Leanpub book, you get free updates for as long as the author updates the book! Many authors use Leanpub to publish their books in-progress, while they are writing them. All readers get free updates, regardless of when they bought the book or how much they paid (including free).

Most Leanpub books are available in PDF (for computers) and EPUB (for phones, tablets and Kindle). The formats that a book includes are shown at the top right corner of this page.

Finally, Leanpub books don't have any DRM copy-protection nonsense, so you can easily read them on any supported device.

Learn more about Leanpub's ebook formats and where to read them

Write and Publish on Leanpub

You can use Leanpub to easily write, publish and sell in-progress and completed ebooks and online courses!

Leanpub is a powerful platform for serious authors, combining a simple, elegant writing and publishing workflow with a store focused on selling in-progress ebooks.

Leanpub is a magical typewriter for authors: just write in plain text, and to publish your ebook, just click a button. (Or, if you are producing your ebook your own way, you can even upload your own PDF and/or EPUB files and then publish with one click!) It really is that easy.

Learn more about writing on Leanpub