4from sphinx_build_tools import load_sphinx_config
5from searx.version import VERSION_STRING
6from pallets_sphinx_themes import ProjectLink
8GIT_URL = os.environ.get("GIT_URL", "https://github.com/asciimoo/searx")
9GIT_BRANCH =os.environ.get("GIT_BRANCH", "master")
10SEARX_URL = os.environ.get("SEARX_URL", "https://searx.me")
11DOCS_URL = os.environ.get("DOCS_URL", "https://asciimoo.github.io/searx/")
13# Project --------------------------------------------------------------
16copyright = u'2015-2020, Adam Tauber, Noémi Ványi'
17author = u'Adam Tauber'
18release, version = VERSION_STRING, VERSION_STRING
19highlight_language = 'none'
21# General --------------------------------------------------------------
27exclude_patterns = ['build-templates/*.rst']
29from searx import webapp
31 'webapp': dict(**webapp.__dict__)
34# usage:: lorem :patch:`f373169` ipsum
38extlinks['wiki'] = ('https://github.com/asciimoo/searx/wiki/%s', ' ')
39extlinks['pull'] = ('https://github.com/asciimoo/searx/pull/%s', 'PR ')
41# links to custom brand
42extlinks['origin'] = (GIT_URL + '/blob/' + GIT_BRANCH + '/%s', 'git://')
43extlinks['patch'] = (GIT_URL + '/commit/%s', '#')
44extlinks['search'] = (SEARX_URL + '/%s', '#')
45extlinks['docs'] = (DOCS_URL + '/%s', 'docs: ')
46extlinks['pypi'] = ('https://pypi.org/project/%s', 'PyPi: ')
47extlinks['man'] = ('https://manpages.debian.org/jump?q=%s', '')
49# 'https://www.sphinx-doc.org/en/master/usage/restructuredtext/roles.html#role-%s', '')
51 'http://docutils.sourceforge.net/docs/ref/rst/restructuredtext.html#%s', '')
53 'http://docutils.sourceforge.net/docs/ref/rst/roles.html#%s', '')
55 'http://docutils.sourceforge.net/docs/ref/rst/directives.html#%s', '')
57 'https://ctan.org/pkg/%s', 'CTAN: ')
61 'sphinx.ext.extlinks',
62 'sphinx.ext.viewcode',
64 "sphinx.ext.intersphinx",
65 "pallets_sphinx_themes",
66 "sphinx_issues", # https://github.com/sloria/sphinx-issues/blob/master/README.rst
67 "sphinxcontrib.jinja", # https://github.com/tardyp/sphinx-jinja
68 "sphinxcontrib.programoutput", # https://github.com/NextThought/sphinxcontrib-programoutput
69 'linuxdoc.rstFlatTable', # Implementation of the 'flat-table' reST-directive.
70 'linuxdoc.kfigure', # Sphinx extension which implements scalable image handling.
71 "sphinx_tabs.tabs", # https://github.com/djungelorm/sphinx-tabs
74intersphinx_mapping = {
75 "python": ("https://docs.python.org/3/", None),
76 "flask": ("https://flask.palletsprojects.com/", None),
77 # "werkzeug": ("https://werkzeug.palletsprojects.com/", None),
78 "jinja": ("https://jinja.palletsprojects.com/", None),
79 "linuxdoc" : ("https://return42.github.io/linuxdoc/", None),
80 "sphinx" : ("https://www.sphinx-doc.org/en/master/", None),
83issues_github_path = "asciimoo/searx"
85# HTML -----------------------------------------------------------------
87sys.path.append(os.path.abspath('_themes'))
88html_theme_path = ['_themes']
91# sphinx.ext.imgmath setup
92html_math_renderer = 'imgmath'
93imgmath_image_format = 'svg'
95# sphinx.ext.imgmath setup END
97html_theme_options = {"index_sidebar_logo": True}
100 ProjectLink("Source", GIT_URL),
101 ProjectLink("Wiki", "https://github.com/asciimoo/searx/wiki"),
102 ProjectLink("Public instances", "https://searx.space/"),
103 ProjectLink("Twitter", "https://twitter.com/Searx_engine"),
107 "**": ["project.html", "relations.html", "searchbox.html"],
109singlehtml_sidebars = {"index": ["project.html", "localtoc.html"]}
110html_static_path = ["static"]
111html_logo = "static/img/searx_logo_small.png"
112html_title = "Searx Documentation ({})".format("Searx-{}.tex".format(VERSION_STRING))
113html_show_sourcelink = False
115# LaTeX ----------------------------------------------------------------
118 (master_doc, "searx-{}.tex".format(VERSION_STRING), html_title, author, "manual")
121# ------------------------------------------------------------------------------
122# Since loadConfig overwrites settings from the global namespace, it has to be
123# the last statement in the conf.py file
124# ------------------------------------------------------------------------------
125load_sphinx_config(globals())
keysesc to close
- j k
- move down, up
- enter
- open
- esc
- back, or up a level
- 1 2 3 4
- readme, files, commits, refs
- /
- filter
- y
- copy the clone command
- c
- compare the chosen commit with another (or shift-click both)
- ?
- show or hide this list