diff --git a/docs/api.rst b/docs/api.rst new file mode 100644 index 0000000..0e0b570 --- /dev/null +++ b/docs/api.rst @@ -0,0 +1,11 @@ +API +=== + +.. autosummary:: + :toctree: DIRNAME + + blag.__init__ + blag.version + blag.blag + blag.markdown + blag.devserver diff --git a/docs/conf.py b/docs/conf.py index 4778871..600980c 100644 --- a/docs/conf.py +++ b/docs/conf.py @@ -9,10 +9,12 @@ # If extensions (or modules to document with autodoc) are in another directory, # add these directories to sys.path here. If the directory is relative to the # documentation root, use os.path.abspath to make it absolute, like shown here. -# -# import os -# import sys -# sys.path.insert(0, os.path.abspath('.')) + +import os +import sys +sys.path.insert(0, os.path.abspath('..')) + +import blag # -- Project information ----------------------------------------------------- @@ -22,7 +24,7 @@ copyright = '2021, Bastian Venthur' author = 'Bastian Venthur' # The full version, including alpha/beta/rc tags -release = '0.0.0' +release = blag.__VERSION__ # -- General configuration --------------------------------------------------- @@ -31,6 +33,9 @@ release = '0.0.0' # extensions coming with Sphinx (named 'sphinx.ext.*') or your custom # ones. extensions = [ + 'sphinx.ext.autosummary', + 'sphinx.ext.autodoc', + 'sphinx.ext.napoleon', ] # Add any paths that contain templates here, relative to this directory. @@ -52,4 +57,13 @@ html_theme = 'alabaster' # Add any paths that contain custom static files (such as style sheets) here, # relative to this directory. They are copied after the builtin static files, # so a file named "default.css" will overwrite the builtin "default.css". -html_static_path = ['_static'] \ No newline at end of file +html_static_path = ['_static'] + +autodoc_default_options = { + 'members': True, + 'undoc-members': True, + 'special-members': True, + 'secret-members': True, +} + +autosummary_generate = True diff --git a/docs/index.rst b/docs/index.rst index 10b6ab3..f1972bb 100644 --- a/docs/index.rst +++ b/docs/index.rst @@ -10,6 +10,7 @@ Welcome to blag's documentation! :maxdepth: 2 :caption: Contents: + api.rst Indices and tables