-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathconf.py
More file actions
48 lines (40 loc) · 1.01 KB
/
conf.py
File metadata and controls
48 lines (40 loc) · 1.01 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
import doctest
master_doc = "README"
extensions = [
"sphinx.ext.doctest",
"sphinx.ext.napoleon",
"sphinx.ext.autodoc",
"sphinx.ext.intersphinx",
"sphinx_rtd_theme",
]
project = "🎯 doit interface"
napoleon_custom_sections = [("Returns", "params_style")]
plot_formats = [
("png", 144),
]
html_theme = "sphinx_rtd_theme"
doctest_global_setup = """
from doit_interface import *
import os
import tempfile
# Use temporary working directory.
_cwd = os.getcwd()
tmpdir = tempfile.TemporaryDirectory()
os.chdir(tmpdir.name)
manager = Manager()
manager.__enter__()
"""
doctest_global_cleanup = """
manager.__exit__()
# Change back to original directory.
os.chdir(_cwd)
tmpdir.cleanup()
"""
doctest_default_flags = doctest.NORMALIZE_WHITESPACE | doctest.ELLIPSIS
# Configure autodoc to avoid excessively long fully-qualified names.
add_module_names = False
autodoc_typehints_format = "short"
intersphinx_mapping = {
"python": ("https://docs.python.org/3", None),
"doit": ("https://pydoit.org", None),
}