There are two essential goals when creating a literate program:
- A working program: This is the code, extracted from the source document(s) and prepared for the compiler or interpreter.
- Easy-to-read documentation: This is the explanation, plus the code, plus any helpful markup prepared for the presentation. This document could be in HTML, ready to be viewed, or it could be in RST, and we'd use docutils rst2html.py to convert it to HTML. Alternatively, it could be in LaTeX and we run it through a LaTeX processor to create a PDF document.
The working program goal means that our literate programming document will cover the entire suite of the source code files. While this seems daunting, we have to remember ...