Generate documentation (HTML?) for my module.

Hi,

How do I generate the documentation from the docstrings in my module? Is there some python module available?

My module has the required syntax for ansible module documentation.

module: xxx
short_description: xxxx
description:

  • xxxx
  • xxx

options:
xxx:
description:

  • xxxx
    required: false
    default: null

author: xxx
updates: [ ‘XXX’ ]
“”"

EXAMPLES = ‘’’

xxx

  • xxx: yyy
    ‘’’

Thanks
Kashyap

This is handled by the “make docs” target.

We run this periodically to update module docs on the website, so you don’t have to run it yourself.

You can also use the “ansible-doc” CLI utility.

We run this periodically to update module docs on the website, so you don’t have to run it yourself.
My aim is to debug (check it out) how it looks.

ansible-doc does exactly what I wanted, but only for cli. Is there another script I can run for generating HTML?

“make webdocs” generates the entire doc site, which is what we have up for ansibleworks.com, where the official docs reside.

I am in the process of writing webdocs for the forthcoming Junos modules. Is there a way to re-generate only a single file; i.e. the module I am working on? This way I would not need to re-generate the entire collection of files each time I make an edit and want to verify the HTML. The rebuild process is not too long, but if there was a known way to do just one file I would prefer that :slight_smile:

Thank you!