Commit 292ae0ac by Stephen Fromm

Merge pull request #1774 from jpmens/adoc1

cleanup Example output in ansible-doc
parents 23f2a7fc 52a55a35
...@@ -89,8 +89,10 @@ def print_man(doc): ...@@ -89,8 +89,10 @@ def print_man(doc):
subsequent_indent=opt_indent) subsequent_indent=opt_indent)
for ex in doc['examples']: if 'examples' in doc and len(doc['examples']) > 0:
print "%s%s" % (opt_indent, ex['code']) print "Example%s:\n" % ('' if len(doc['examples']) < 2 else 's')
for ex in doc['examples']:
print "%s\n" % (ex['code'])
def print_snippet(doc): def print_snippet(doc):
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment