2.4 Writing better docstrings with RST markup
When we have a useful script, we often need to leave notes on what it does, how it works, and when it should be used. Many tools for producing documentation, including Docutils, work with RST markup. This allows us to write plain text documentation. It can include some special punctuation to pick a bold or italic font variant to call attention to details. In addition, RST permits organizing content via lists and section headings.
2.4.1 Getting ready
In the Including descriptions and documentation recipe, we looked at putting some basic documentation into a module. We’ll look at a few of the RST formatting rules for creating readable documentation.
2.4.2 How to do it...
Start with an outline of the key point, creating RST section titles to organize the material. A section title has a one-line title followed by a line of underline characters...