diff options
author | Zane Bitter <zbitter@redhat.com> | 2018-04-06 15:10:28 -0400 |
---|---|---|
committer | Zane Bitter <zbitter@redhat.com> | 2018-04-06 15:10:28 -0400 |
commit | bf2b57a92b338899e29bdfd62bb74a456da10ee8 (patch) | |
tree | 4a0ca163b22d0157ef403be5d711284763471268 /doc | |
parent | f41ad78cd49788bc8589b849a888aeb9bb916997 (diff) | |
download | python-heatclient-bf2b57a92b338899e29bdfd62bb74a456da10ee8.tar.gz |
Improve titles of generated API documentation
Change-Id: I1a5820e979418063b7e203acc5e07ce0e7be30bd
Diffstat (limited to 'doc')
-rw-r--r-- | doc/source/ext/gen_ref.py | 16 |
1 files changed, 10 insertions, 6 deletions
diff --git a/doc/source/ext/gen_ref.py b/doc/source/ext/gen_ref.py index 15ff818..cbe936b 100644 --- a/doc/source/ext/gen_ref.py +++ b/doc/source/ext/gen_ref.py @@ -37,7 +37,7 @@ def gen_ref(ver, title, names): ".. toctree::\n" " :maxdepth: 1\n" "\n") % {"title": title, "signs": "=" * len(title)}) - for name in names: + for name, sec_title in names.items(): idx.write(" %s\n" % name) rstpath = os.path.join(refdir, "%s.rst" % name) with open(rstpath, "w") as rst: @@ -49,11 +49,15 @@ def gen_ref(ver, title, names): " :undoc-members:\n" " :show-inheritance:\n" " :noindex:\n") - % {"title": name.capitalize(), - "signs": "=" * len(name), + % {"title": sec_title, + "signs": "=" * len(sec_title), "pkg": pkg, "name": name}) -gen_ref("", "Client Reference", ["client", "exc"]) +gen_ref("", "Client Reference", {"client": "Client", "exc": "Exceptions"}) gen_ref("v1", "Version 1 API Reference", - ["stacks", "resources", "events", "actions", - "software_configs", "software_deployments"]) + {"stacks": "Stacks", + "resources": "Resources", + "events": "Events", + "actions": "Actions", + "software_configs": "Software Configs", + "software_deployments": "Software Deployments"}) |