Browse Source

[mod] doc - in sidebar, add links to the reST sources

Offer links to the reST sources (aka) html_show_sourcelink [1].  Links to the
reST source are sometimes very helpful, especially in our resT-Primer [2] :)

[1] https://www.sphinx-doc.org/en/master/usage/configuration.html#confval-html_show_sourcelink
[2] https://searxng.github.io/searxng/dev/reST.html

Related-to: https://github.com/pallets/pallets-sphinx-themes/issues/32
Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
Markus Heiser 3 years ago
parent
commit
2cc2406859
1 changed files with 2 additions and 2 deletions
  1. 2 2
      docs/conf.py

+ 2 - 2
docs/conf.py

@@ -130,13 +130,13 @@ if CONTACT_URL:
     html_context["project_links"].append(ProjectLink("Contact", CONTACT_URL))
     html_context["project_links"].append(ProjectLink("Contact", CONTACT_URL))
 
 
 html_sidebars = {
 html_sidebars = {
-    "**": ["project.html", "relations.html", "searchbox.html"],
+    "**": ["project.html", "relations.html", "searchbox.html", "sourcelink.html"],
 }
 }
 singlehtml_sidebars = {"index": ["project.html", "localtoc.html"]}
 singlehtml_sidebars = {"index": ["project.html", "localtoc.html"]}
 html_static_path = ["static"]
 html_static_path = ["static"]
 html_logo = "static/img/searx_logo_small.png"
 html_logo = "static/img/searx_logo_small.png"
 html_title = "SearXNG Documentation ({})".format(VERSION_STRING)
 html_title = "SearXNG Documentation ({})".format(VERSION_STRING)
-html_show_sourcelink = False
+html_show_sourcelink = True
 
 
 # LaTeX ----------------------------------------------------------------
 # LaTeX ----------------------------------------------------------------