Debian Codegraph @

docs/conf.py

raw
1 from pallets_sphinx_themes import get_version
2 from pallets_sphinx_themes import ProjectLink
3
4 # Project --------------------------------------------------------------
5
6 project = "MarkupSafe"
7 copyright = "2010 Pallets"
8 author = "Pallets"
9 release, version = get_version("MarkupSafe")
10
11 # General --------------------------------------------------------------
12
13 default_role = "code"
14 extensions = [
15 "sphinx.ext.autodoc",
16 "sphinx.ext.extlinks",
17 "sphinx.ext.intersphinx",
18 "sphinxcontrib.log_cabinet",
19 "pallets_sphinx_themes",
20 ]
21 autodoc_member_order = "bysource"
22 autodoc_typehints = "description"
23 autodoc_preserve_defaults = True
24 extlinks = {
25 "issue": ("https://github.com/pallets/markupsafe/issues/%s", "#%s"),
26 "pr": ("https://github.com/pallets/markupsafe/pull/%s", "#%s"),
27 }
28 intersphinx_mapping = {
29 "python": ("https://docs.python.org/3/", None),
30 }
31
32 # HTML -----------------------------------------------------------------
33
34 html_theme = "jinja"
35 html_theme_options = {"index_sidebar_logo": False}
36 html_context = {
37 "project_links": [
38 ProjectLink("Donate", "https://palletsprojects.com/donate"),
39 ProjectLink("PyPI Releases", "https://pypi.org/project/MarkupSafe/"),
40 ProjectLink("Source Code", "https://github.com/pallets/markupsafe/"),
41 ProjectLink("Issue Tracker", "https://github.com/pallets/markupsafe/issues/"),
42 ProjectLink("Chat", "https://discord.gg/pallets"),
43 ]
44 }
45 html_sidebars = {
46 "index": ["project.html", "localtoc.html", "searchbox.html", "ethicalads.html"],
47 "**": ["localtoc.html", "relations.html", "searchbox.html", "ethicalads.html"],
48 }
49 singlehtml_sidebars = {"index": ["project.html", "localtoc.html", "ethicalads.html"]}
50 html_static_path = ["_static"]
51 html_favicon = "_static/markupsafe-icon.svg"
52 html_logo = "_static/markupsafe-logo.svg"
53 html_title = f"MarkupSafe Documentation ({version})"
54 html_show_sourcelink = False