Migrate output format doc generation ksh to jinja2
This commit replaces the ksh-based templating with Python Jinja2
templating.
Previously output.html was generated with:
- output.1
- the output of mkoutput.sh
- output.2
My end goal here is to make it much simpler to generate more complex
output format docs - however I've made this change so that the output is
virtually unchanged, except for HTML-escaping a single apostrophe.
My plan is to follow this up with adding some more features to the
output format documentation.
Templating in general provides a few opportunities:
- safe auto-html-escaping
- easier editing, easier adding of more data
- some separation of logic and templating
- inclusion of subtemplates
I chose Jinja2 because:
- It's the most popular Python templating engine, used by mature
products like Ansible and Flask.
- Graphviz's docs generation already takes a dependency on Python for
jconvert.py.
- The Python language is pretty accessible to contributors.
- Jinja2 seems pretty stable, going back to 2007. Unlikely to break
soon.
Alternatives considered:
- I could just as well have gone with Go's stdlib template/html but I
don't think Go is already used to build Graphviz, and Go isn't as
popular as Python, so not as accessible to contributors.
- Python Django templates: they're pretty similar to Jinja2, but I think
Django's templates are more heavyweight