Skip to content

Commit

Permalink
doc: enable apidoc generation
Browse files Browse the repository at this point in the history
Signed-off-by: Jan Luebbe <jlu@pengutronix.de>
  • Loading branch information
jluebbe committed Mar 20, 2017
1 parent 8f6f770 commit c37dce8
Show file tree
Hide file tree
Showing 2 changed files with 18 additions and 1 deletion.
18 changes: 17 additions & 1 deletion doc/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -156,4 +156,20 @@
]



# -- Options for autodoc --------------------------------------------------

autodoc_member_order = 'bysource'
autodoc_mock_imports = ['onewire', 'txaio']

def run_apidoc(_):
from sphinx.apidoc import main
import os
import sys
output_path = os.path.join(
os.path.abspath(os.path.dirname(__file__)),
'api'
)
main(['', '-T', '-o', output_path, 'labgrid', '--force'])

def setup(app):
app.connect('builder-inited', run_apidoc)
1 change: 1 addition & 0 deletions doc/index.rst
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ Welcome to labgrid's documentation!
development
components
design_decisions
api/labgrid
:maxdepth: 2
:caption: Contents:

Expand Down

0 comments on commit c37dce8

Please sign in to comment.