mirror of
https://github.com/ansible-collections/community.general.git
synced 2025-06-28 11:10:21 -07:00
Merge pull request #2942 from stoned/doc-requirements
Fix empty requirements specifications in modules documentation
This commit is contained in:
commit
206b34783f
3 changed files with 4 additions and 4 deletions
|
@ -86,7 +86,7 @@ def print_man(doc):
|
||||||
subsequent_indent=opt_indent)
|
subsequent_indent=opt_indent)
|
||||||
|
|
||||||
|
|
||||||
if 'requirements' in doc and len(doc['requirements']) > 0:
|
if 'requirements' in doc and doc['requirements'] is not None and len(doc['requirements']) > 0:
|
||||||
req = ", ".join(doc['requirements'])
|
req = ", ".join(doc['requirements'])
|
||||||
print "Requirements:%s\n" % textwrap.fill(tty_ify(req), initial_indent=" ",
|
print "Requirements:%s\n" % textwrap.fill(tty_ify(req), initial_indent=" ",
|
||||||
subsequent_indent=opt_indent)
|
subsequent_indent=opt_indent)
|
||||||
|
|
|
@ -53,7 +53,7 @@ examples:
|
||||||
notes:
|
notes:
|
||||||
- Since Ansible version 0.9, templates are loaded with C(trim_blocks=True).
|
- Since Ansible version 0.9, templates are loaded with C(trim_blocks=True).
|
||||||
- 'You can override jinja2 settings by adding a special header to template file.
|
- 'You can override jinja2 settings by adding a special header to template file.
|
||||||
i.e. c(#jinja2: trim_blocks: False)'
|
i.e. C(#jinja2: trim_blocks: False)'
|
||||||
requirements: null
|
requirements: []
|
||||||
author: Michael DeHaan
|
author: Michael DeHaan
|
||||||
'''
|
'''
|
||||||
|
|
|
@ -64,7 +64,7 @@ examples:
|
||||||
- code: "wait_for: port=8000 delay=10"
|
- code: "wait_for: port=8000 delay=10"
|
||||||
description: "Example from Ansible Playbooks"
|
description: "Example from Ansible Playbooks"
|
||||||
notes: []
|
notes: []
|
||||||
requirements: null
|
requirements: []
|
||||||
author: Jeroen Hoekx
|
author: Jeroen Hoekx
|
||||||
'''
|
'''
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue