Sphinx EPUB and Print

Let's say you want to self-publish an ebook and a print-on-demand paperback book.

This isn't impossible, nor is it particularly easy. Here's what I've learned.

Basic Workflow

You've got two obvious paths to make sure your EPUB book and your print-on-demand book match:

  1. Convert EPUB to Print. This generally means …
more ...


The "Build Script" Idea

In compiled languages, the build script or makefile is pretty important. Java has maven (and gradle and ant) for this job.

Python doesn't really have much for this. Mostly because it's needless.

However.

Some folks like the idea of a build script. I've been asked for suggestions.

First and foremost …

more ...



Comments, Assertions and Unit Tests

See "Commenting the Code".

This posting tickled my fancy because it addressed the central issue of "what requires comments outside Python docstrings". All functions, classes, modules and packages require docstrings. That's clear. But which lines of code require additional documentation?

We use Sphinx, so we make extensive use of docstrings …

more ...


Semantic Markup -- RST vs. XML

I have very mixed feelings about XML's usability.

An avowed goal of the inventors of XML was "XML documents should be human-legible and reasonably clear." While I like to think that "legible" means usable, I'm feeling that legibility is really a minimal standard; I think it's a polite way of …

more ...


All Those TODO's

About a year ago, we started out doing Python development with simple rst2htmldocuments for requirements, design, etc. In the code, we had comments that used epydoc with the epytextmarkup language.

No, it wasn’t confusing. Free-text documents (requirements, architecture, design, test plans, etc.) are easy and fun to …

more ...