mirror of
https://github.com/fhswf/aki_prj23_transparenzregister.git
synced 2025-04-22 08:12:54 +02:00
104 lines
3.6 KiB
Python
104 lines
3.6 KiB
Python
"""Python sphinx documentation build configuration."""
|
|
# Configuration file for the Sphinx documentation builder.
|
|
#
|
|
# For the full list of built-in configuration values, see the documentation:
|
|
# https://www.sphinx-doc.org/en/master/usage/configuration.html
|
|
import os
|
|
import sys
|
|
from importlib.metadata import metadata
|
|
from typing import Final
|
|
|
|
# -- Project information -----------------------------------------------------
|
|
# https://www.sphinx-doc.org/en/master/usage/configuration.html#project-information
|
|
|
|
_DISTRIBUTION_METADATA = metadata("aki-prj23-transparenzregister")
|
|
|
|
__author__: Final[str] = _DISTRIBUTION_METADATA["Author"]
|
|
__email__: Final[str] = _DISTRIBUTION_METADATA["Author-email"]
|
|
__version__: Final[str] = _DISTRIBUTION_METADATA["Version"]
|
|
|
|
project: Final[str] = "transparenzregister"
|
|
copyright: Final[str] = "2023, AKI PRJ23" # noqa: A001
|
|
author: Final[str] = __author__
|
|
version: Final[str] = __version__
|
|
release: Final[str] = __version__
|
|
|
|
|
|
sys.path.insert(0, os.path.abspath("../src")) # Add the path to your Python package
|
|
sys.path.insert(0, os.path.abspath("../src/aki_prj23_transparenzregister"))
|
|
|
|
|
|
# -- General configuration ---------------------------------------------------
|
|
# https://www.sphinx-doc.org/en/master/usage/configuration.html#general-configuration
|
|
|
|
extensions: Final[list[str]] = [
|
|
"sphinx.ext.autodoc",
|
|
"nbsphinx",
|
|
"myst_parser",
|
|
"sphinx.ext.napoleon",
|
|
"sphinx_copybutton",
|
|
"sphinx_autodoc_typehints",
|
|
"sphinx.ext.intersphinx",
|
|
"sphinx.ext.autosectionlabel",
|
|
"sphinx.ext.viewcode",
|
|
"IPython.sphinxext.ipython_console_highlighting",
|
|
"sphinxcontrib.mermaid",
|
|
"notfound.extension",
|
|
"sphinxcontrib.drawio",
|
|
"sphinx_git",
|
|
]
|
|
|
|
# templates_path : Final[list[str]] = ["_templates"]
|
|
exclude_patterns: Final[list[str]] = ["_build", "Thumbs.db", ".DS_Store", "templates"]
|
|
|
|
root_doc: Final[str] = "index"
|
|
|
|
autodoc_default_flags: Final[list[str]] = [
|
|
"members",
|
|
"inherited-members",
|
|
"show-inheritance",
|
|
]
|
|
autodoc_class_signature: Final[str] = "separated"
|
|
autodoc_default_options: Final[dict[str, bool]] = {
|
|
_: True for _ in autodoc_default_flags
|
|
}
|
|
autodoc_typehints: Final[str] = "signature"
|
|
simplify_optional_unions: Final[bool] = False
|
|
typehint_defaults: Final[str] = "comma"
|
|
source_suffix: Final[list[str]] = [".rst", ".md"]
|
|
mermaid_output_format: Final[str] = "raw"
|
|
|
|
# -- Options for HTML output -------------------------------------------------
|
|
# https://www.sphinx-doc.org/en/master/usage/configuration.html#options-for-html-output
|
|
|
|
html_theme: Final[str] = "sphinx_rtd_theme"
|
|
html_static_path: Final[list[str]] = ["_static"]
|
|
html_css_files = [
|
|
"css/custom.css",
|
|
]
|
|
|
|
napoleon_google_docstring: Final[bool] = True
|
|
napoleon_numpy_docstring: Final[bool] = False
|
|
|
|
nbsphinx_execute = "never"
|
|
|
|
intersphinx_mapping: Final[dict[str, tuple[str, None]]] = {
|
|
"python": ("https://docs.python.org/3", None),
|
|
"pandas": ("https://pandas.pydata.org/docs/", None),
|
|
"numpy": ("https://numpy.org/doc/stable/", None),
|
|
"matplotlib": ("https://matplotlib.org/stable/", None),
|
|
"scikit-learn": ("https://scikit-learn.org/stable/", None),
|
|
"sphinx": ("https://docs.sympy.org/latest/", None),
|
|
"plotly": ("https://plotly.com/python-api-reference/", None),
|
|
"networkx": ("https://networkx.org/documentation/stable/", None),
|
|
"scipy": ("https://docs.scipy.org/doc/scipy/reference/", None),
|
|
"sqlalchemy": ("https://docs.sqlalchemy.org/en/14", None),
|
|
}
|
|
|
|
myst_enable_extensions: Final[list[str]] = ["html_image"]
|
|
|
|
notfound_urls_prefix = "/"
|
|
|
|
myst_enable_extensions = ["dollarmath", "amsmath"]
|
|
drawio_default_transparency = True
|