-
Notifications
You must be signed in to change notification settings - Fork 2
Expand file tree
/
Copy pathconf.py
More file actions
120 lines (97 loc) · 3.34 KB
/
conf.py
File metadata and controls
120 lines (97 loc) · 3.34 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
# -*- coding: utf-8 -*-
#
# Configuration file for the Sphinx documentation builder.
#
# This file does only contain a selection of the most common options. For a
# full list see the documentation:
# https://www.sphinx-doc.org/en/stable/usage/configuration.html
# -- Path setup --------------------------------------------------------------
import os
import sys
import time
# Ensure the *repo root* is on sys.path so autodoc imports the local package.
# This works whether conf.py is in docs/ or docs/source/.
DOCS_DIR = os.path.abspath(os.path.dirname(__file__))
REPO_ROOT = os.path.abspath(os.path.join(DOCS_DIR, ".."))
sys.path.insert(0, REPO_ROOT)
# -- Project information -----------------------------------------------------
project = "CodeEntropy"
copyright_first_year = "2022"
copyright_owners = "CCPBioSim"
author = "CCPBioSim"
current_year = str(time.localtime().tm_year)
copyright_year_string = (
current_year
if current_year == copyright_first_year
else f"{copyright_first_year}-{current_year}"
)
copyright = f"{copyright_year_string}, {copyright_owners}. All rights reserved"
version = ""
release = ""
# -- General configuration ---------------------------------------------------
extensions = [
"sphinx.ext.autosummary",
"sphinx.ext.autodoc",
"sphinx.ext.mathjax",
"sphinx.ext.viewcode",
"sphinx.ext.napoleon",
"sphinx.ext.intersphinx",
"sphinx.ext.extlinks",
"nbsphinx",
"sphinx_copybutton",
]
# Autosummary (API stubs)
autosummary_generate = True
# Napoleon: Google-style docstrings
napoleon_google_docstring = True
napoleon_numpy_docstring = False
# Render Google "Args:" into :param: fields (recommended)
napoleon_use_param = True
napoleon_use_rtype = True
napoleon_use_ivar = True
# (Optional) If some modules have optional heavy deps, you can mock them here:
# autodoc_mock_imports = ["MDAnalysis"]
templates_path = ["_templates"]
source_suffix = ".rst"
master_doc = "index"
language = "en"
exclude_patterns = ["_build", "Thumbs.db", ".DS_Store"]
pygments_style = "default"
# -- Options for HTML output -------------------------------------------------
html_theme = "furo"
html_theme_options = {
"light_logo": "logos/biosim-codeentropy_logo_light.png",
"dark_logo": "logos/biosim-codeentropy_logo_dark.png",
}
html_static_path = ["_static"]
# -- Options for HTMLHelp output ---------------------------------------------
htmlhelp_basename = "CodeEntropydoc"
# -- Options for LaTeX output ------------------------------------------------
latex_elements = {}
latex_documents = [
(
master_doc,
"CodeEntropy.tex",
"CodeEntropy Documentation",
"CodeEntropy",
"manual",
),
]
# -- Options for manual page output ------------------------------------------
man_pages = [(master_doc, "CodeEntropy", "CodeEntropy Documentation", [author], 1)]
# -- Options for Texinfo output ----------------------------------------------
texinfo_documents = [
(
master_doc,
"CodeEntropy",
"CodeEntropy Documentation",
author,
"CodeEntropy",
"CodeEntropy tool with POSEIDON code integrated to form a complete and "
"generally applicable set of tools for calculating entropy",
"Miscellaneous",
),
]
# -- Extension configuration -------------------------------------------------
def setup(app):
app.add_css_file("custom.css")