Skip to content

Commit

Permalink
Added support for autodoc --templatedir option
Browse files Browse the repository at this point in the history
  • Loading branch information
itsmoosh authored and stephenfin committed Jan 16, 2024
1 parent d0505e0 commit a61507a
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 0 deletions.
1 change: 1 addition & 0 deletions sphinxcontrib/apidoc/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@ def setup(app: Sphinx) -> Dict[str, Any]:
app.connect('builder-inited', ext.builder_inited)
app.add_config_value('apidoc_module_dir', None, 'env', [str])
app.add_config_value('apidoc_output_dir', 'api', 'env', [str])
app.add_config_value('apidoc_template_dir', 'templates', 'env', [str])
app.add_config_value('apidoc_excluded_paths', [], 'env', [[str]])
app.add_config_value('apidoc_separate_modules', False, 'env', [bool])
app.add_config_value('apidoc_toc_file', None, 'env', [str, bool])
Expand Down
3 changes: 3 additions & 0 deletions sphinxcontrib/apidoc/ext.py
Original file line number Diff line number Diff line change
Expand Up @@ -64,6 +64,9 @@ def cmd_opts():

yield '--output-dir'
yield output_dir

yield '--templatedir'
yield template_dir

for arg in extra_args:
yield arg
Expand Down

0 comments on commit a61507a

Please sign in to comment.