Skip to content

Keystone

Simple things should be simple, and difficult things should be possible.

Keystone turns a Markdown manuscript into professional-quality PDF, EPUB, DOCX, and ODT — one source, every format. You write plain text, choose a target (book, report, article), and Keystone typesets the result with Pandoc, XeLaTeX, and a pinned Docker image. No LaTeX expertise required — you only need Docker and make.

Think of it as a compiler

A compiler takes source in one language and emits artifacts in another. Keystone does the same for books — your Markdown manuscript, plus pandoc.yaml for metadata and shortcuts.yaml for styling:

manuscript   ──►   Keystone   ──►   PDF · EPUB · DOCX · ODT

Your source stays clean and portable. Change the target and the same manuscript reflows into a different book.

Write your book like code

Your manuscript is source code — plain Markdown, nothing more. That single decision frees you from the WYSIWYG trap: no fighting formatting instead of writing, no styling you can't change once and apply everywhere, no book locked inside an opaque format you can't diff or review. Write like a developer and you keep full control of your content pipeline.

  • Content and layout stay separate. Markdown holds the words; the target and pandoc.yaml hold the design. Change the look once, globally — never chase formatting from page to page.
  • One source, every format. A single manuscript produces print-ready PDF, reflowable EPUB, and editable DOCX/ODT — no parallel copies to keep in sync.
  • Professional typography without the learning curve. KOMA-Script book classes, real font embedding, running headers, and footnotes are configured, not hand-coded.
  • Versioned like software. Plain text is diff-able, reviewable, and branchable — your whole book under version control, every change visible.
  • Durable and portable. Markdown is just text: readable on any machine, old or new, decades from now — and editable in any IDE or text editor you already like.
  • Reproducible builds. Everything runs in a version-pinned image, so the book you build today builds identically next year.

How you use it

You don't install Keystone — you start from a template and drive it with make:

make publish              # build a PDF
make publish format=epub  # build an EPUB
make all                  # PDF, EPUB, and DOCX

Two templates ship today:

  • core-slim — the everyday template. Pulls a prebuilt image; you just write. Start here.
  • core — the full template. Builds the image locally and ships the whole engine, for authors who want to understand or customize the internals.

See Templates for how to choose.

Where to start

New to Keystone? The Quickstart takes you from an empty template to a finished PDF. From there:

  • Writing — format dialogue, add a scene break, place a figure, and every other authoring task.
  • Configuration — title, target, fonts, page layout, and the rest of pandoc.yaml.
  • Shortcuts — Keystone's styling API, and how to define your own project vocabulary on top of it.

Where to take it next

Keystone's PDF and EPUB come out publication-ready. When the writing's done and you want the book in readers' hands, Publishing your book covers the next step — print-on-demand and e-book platforms, and what each artifact is good for.


From developers, to authors. Keystone exists so you can focus on writing — not fighting tooling. We do the long, proper thing once in the infrastructure: no hacks, no "just run this extra command", nothing you have to hand-fix. If a fix would require you to act, we don't consider it shipped.