Hi guy,
I'm working on automatic docs generator for Ansible (HTML, e-pub,
HTML, ..), but I find some "inconsistencies", before start to fix it
and send pull request I ask to you what do you think about change
proposal.
# Description
-- Status
Description is an list of string, but sometime I found it is a string
(eg: cron, gem, uri, vagrant, ..)
-- Proposal
Change all description to be a list (Pull reqest 2528 ¹)
-- Workaround
Each docs generator require to add a if condition to check if data is
a string or array, ..
# Version added
-- Status
Version added in documentation sometime is a number, sometime is a
string (eg: string in assemble, nuber in nagios) . This can generate
"error" in parsing.
-- Proposal
Change all items to be string (quote escaped), all version require to have:
MAIN.MINOR.PATCH
maybe we can limit to MAIN.MINOR, but the first releases are 0.0.2, ..
so we can change to "lost" this information and use minor version the
only possible version-change that can add a module.
-- Workaround
Cast data to string before manage this informations and normalize data
before parsing.
# Examples
-- Status
Documentation have two different point to insert examples, the first
is the item examples in DOCUMENTATION. This is a list of items with
code and description.
In some other case there are EXAMPLES that contains a "blob" of data.
I think this is a "historic heritage".
-- Proposal
Move EXAMPLES information in DOCUMENTATION/examples or
DOCUMENTATION/note (eg data in mysql_user is note and not code
example, have code and documentation, ...) and remove EXAMPLES items.
-- Workaround
Manage examples and EXAMPLES in different way, generating
"inconsistent" docs interface.
# Indentation
-- Status
Some data in DOCUMENTATION have 2 space as indentation, some other have 4 space.
-- Proposal
Move all to have 2 space indentation.
-- Workaround
Actually not required, the python parser automatically fix this. I
suggest to normalize as "coding standard" request and not "data
management" error.
Have a great Easter
Bye
Marco