1
|
|
|
# Configuration file for the Sphinx documentation builder. |
2
|
|
|
# |
3
|
|
|
# For the full list of built-in configuration values, see the documentation: |
4
|
|
|
# https://www.sphinx-doc.org/en/master/usage/configuration.html |
5
|
|
|
|
6
|
|
|
import os |
7
|
|
|
import sys |
8
|
|
|
|
9
|
|
|
# Get the project root dir, which is the parent dir of this |
10
|
|
|
cwd = os.getcwd() |
11
|
|
|
project_root = os.path.dirname(cwd) |
12
|
|
|
src_dir = os.path.abspath(os.path.join(project_root, "src")) |
13
|
|
|
|
14
|
|
|
# Insert the project root dir as the first element in the PYTHONPATH. |
15
|
|
|
# This lets us ensure that the source package is imported, and that its |
16
|
|
|
# version is used. |
17
|
|
|
sys.path.insert(0, os.path.join(project_root, "src")) |
18
|
|
|
|
19
|
|
|
# -- Project information ----------------------------------------------------- |
20
|
|
|
# https://www.sphinx-doc.org/en/master/usage/configuration.html#project-information |
21
|
|
|
|
22
|
|
|
project = "decimaldate" |
23
|
|
|
copyright = "2024, Torben Jakobsen" |
24
|
|
|
author = "Torben Jakobsen" |
25
|
|
|
|
26
|
|
|
# -- General configuration --------------------------------------------------- |
27
|
|
|
# https://www.sphinx-doc.org/en/master/usage/configuration.html#general-configuration |
28
|
|
|
|
29
|
|
|
extensions = [ |
30
|
|
|
"sphinx.ext.autodoc", |
31
|
|
|
"sphinx.ext.autosummary", |
32
|
|
|
"sphinx.ext.duration", |
33
|
|
|
"sphinx.ext.intersphinx", |
34
|
|
|
] |
35
|
|
|
|
36
|
|
|
templates_path = ["_templates"] |
37
|
|
|
exclude_patterns = [".DS_Store"] |
38
|
|
|
intersphinx_mapping = {"python": ("https://docs.python.org/3", None)} |
39
|
|
|
|
40
|
|
|
# -- Options for HTML output ------------------------------------------------- |
41
|
|
|
# https://www.sphinx-doc.org/en/master/usage/configuration.html#options-for-html-output |
42
|
|
|
|
43
|
|
|
html_theme = "sphinx_rtd_theme" |
44
|
|
|
html_static_path = ["_static"] |
45
|
|
|
|