Skip to content

Commit

Permalink
tool docs are no longer toc-orphaned
Browse files Browse the repository at this point in the history
  • Loading branch information
myk002 committed Sep 23, 2022
1 parent 3dfb855 commit 8546b29
Showing 1 changed file with 0 additions and 2 deletions.
2 changes: 0 additions & 2 deletions conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -73,13 +73,11 @@ def write_tool_docs():
the original documentation.
"""
for k in doc_all_dirs():
header = ':orphan:\n'
label = ('.. _{name}:\n\n').format(name=k[0])
include = ('.. include:: /{path}\n\n').format(path=k[1])
os.makedirs(os.path.join('docs/tools', os.path.dirname(k[0])),
mode=0o755, exist_ok=True)
with write_file_if_changed('docs/tools/{}.rst'.format(k[0])) as outfile:
outfile.write(header)
if k[0] != 'search':
outfile.write(label)
outfile.write(include)
Expand Down

0 comments on commit 8546b29

Please sign in to comment.