conf.py
This file
Path
docs/conf.py
94 lines · 3.1 KiB · Python
Last changed by
Merge pull request #3554 from pallets/drop-python2David Lordbefore adoptioncd8a374
History of this fileTake it
The walk stopped after 200 commits: lines older than e102e5c point at it.
Merge branch '1.1.x'David Lordbefore adoptiona3f0782
line 1why, one step back1import packaging.versionMerge pull request #2912 from pallets/docs-themeDavid Lordbefore adoption19a0a7d
lines 2–3why, one step back2from pallets_sphinx_themes import get_version3from pallets_sphinx_themes import ProjectLinkMerge pull request #2707 from rochacbruno/lazy_loader_messageDavid Lordbefore adoptione102e5c
lines 4–6why, one step back45# Project --------------------------------------------------------------6Merge pull request #2912 from pallets/docs-themeDavid Lordbefore adoption19a0a7d
line 7why, one step back7project = "Flask"Merge branch '1.0.x'David Lordbefore adoption1351d0a
lines 8–9why, one step back8copyright = "2010 Pallets"9author = "Pallets"Merge pull request #2912 from pallets/docs-themeDavid Lordbefore adoption19a0a7d
line 10why, one step back10release, version = get_version("Flask")Merge pull request #2707 from rochacbruno/lazy_loader_messageDavid Lordbefore adoptione102e5c
lines 11–13why, one step back1112# General --------------------------------------------------------------13Merge pull request #2912 from pallets/docs-themeDavid Lordbefore adoption19a0a7d
line 14why, one step back14master_doc = "index"Merge pull request #2707 from rochacbruno/lazy_loader_messageDavid Lordbefore adoptione102e5c
line 15why, one step back15extensions = [Merge pull request #2912 from pallets/docs-themeDavid Lordbefore adoption19a0a7d
lines 16–19why, one step back16 "sphinx.ext.autodoc",17 "sphinx.ext.intersphinx",18 "sphinxcontrib.log_cabinet",19 "pallets_sphinx_themes",Merge pull request #3174 from icreatedanaccount/masterDavid Lordbefore adoption8ef56c8
line 20why, one step back20 "sphinx_issues",Merge pull request #2707 from rochacbruno/lazy_loader_messageDavid Lordbefore adoptione102e5c
lines 21–22why, one step back21]22intersphinx_mapping = {Merge pull request #2912 from pallets/docs-themeDavid Lordbefore adoption19a0a7d
line 23why, one step back23 "python": ("https://docs.python.org/3/", None),Merge branch '1.0.x'David Lordbefore adoption1351d0a
line 24why, one step back24 "werkzeug": ("https://werkzeug.palletsprojects.com/", None),Merge branch '1.0-maintenance'David Lordbefore adoptionf7d50d4
line 25why, one step back25 "click": ("https://click.palletsprojects.com/", None),Merge pull request #3427 from greyli/update-old-linksDavid Lordbefore adoption25a5d30
line 26why, one step back26 "jinja": ("https://jinja.palletsprojects.com/", None),Merge branch '1.0-maintenance'David Lordbefore adoptionf7d50d4
lines 27–29why, one step back27 "itsdangerous": ("https://itsdangerous.palletsprojects.com/", None),28 "sqlalchemy": ("https://docs.sqlalchemy.org/", None),29 "wtforms": ("https://wtforms.readthedocs.io/en/stable/", None),Merge pull request #2912 from pallets/docs-themeDavid Lordbefore adoption19a0a7d
line 30why, one step back30 "blinker": ("https://pythonhosted.org/blinker/", None),Merge pull request #2707 from rochacbruno/lazy_loader_messageDavid Lordbefore adoptione102e5c
line 31why, one step back31}Merge pull request #3174 from icreatedanaccount/masterDavid Lordbefore adoption8ef56c8
line 32why, one step back32issues_github_path = "pallets/flask"Merge pull request #2707 from rochacbruno/lazy_loader_messageDavid Lordbefore adoptione102e5c
lines 33–35why, one step back3334# HTML -----------------------------------------------------------------35Merge pull request #2912 from pallets/docs-themeDavid Lordbefore adoption19a0a7d
lines 36–37why, one step back36html_theme = "flask"37html_theme_options = {"index_sidebar_logo": False}Merge pull request #2707 from rochacbruno/lazy_loader_messageDavid Lordbefore adoptione102e5c
line 38why, one step back38html_context = {Merge pull request #2912 from pallets/docs-themeDavid Lordbefore adoption19a0a7d
lines 39–45why, one step back39 "project_links": [40 ProjectLink("Donate to Pallets", "https://palletsprojects.com/donate"),41 ProjectLink("Flask Website", "https://palletsprojects.com/p/flask/"),42 ProjectLink("PyPI releases", "https://pypi.org/project/Flask/"),43 ProjectLink("Source Code", "https://github.com/pallets/flask/"),44 ProjectLink("Issue Tracker", "https://github.com/pallets/flask/issues/"),45 ]Merge pull request #2707 from rochacbruno/lazy_loader_messageDavid Lordbefore adoptione102e5c
lines 46–47why, one step back46}47html_sidebars = {Merge branch '1.0.x'David Lordbefore adoption1351d0a
lines 48–49why, one step back48 "index": ["project.html", "localtoc.html", "searchbox.html"],49 "**": ["localtoc.html", "relations.html", "searchbox.html"],Merge pull request #2707 from rochacbruno/lazy_loader_messageDavid Lordbefore adoptione102e5c
line 50why, one step back50}Merge branch '1.0.x'David Lordbefore adoption1351d0a
line 51why, one step back51singlehtml_sidebars = {"index": ["project.html", "localtoc.html"]}Merge pull request #2912 from pallets/docs-themeDavid Lordbefore adoption19a0a7d
lines 52–53why, one step back52html_static_path = ["_static"]53html_favicon = "_static/flask-icon.png"Merge branch '1.0.x'David Lordbefore adoption1351d0a
line 54why, one step back54html_logo = "_static/flask-icon.png"Merge pull request #3554 from pallets/drop-python2David Lordbefore adoptioncd8a374
line 55why, one step back55html_title = f"Flask Documentation ({version})"Merge pull request #2707 from rochacbruno/lazy_loader_messageDavid Lordbefore adoptione102e5c
lines 56–59why, one step back56html_show_sourcelink = False5758# LaTeX ----------------------------------------------------------------59Merge pull request #3554 from pallets/drop-python2David Lordbefore adoptioncd8a374
line 60why, one step back60latex_documents = [(master_doc, f"Flask-{version}.tex", html_title, author, "manual")]Merge pull request #2707 from rochacbruno/lazy_loader_messageDavid Lordbefore adoptione102e5c
lines 61–64why, one step back6162# Local Extensions -----------------------------------------------------6364Merge pull request #2912 from pallets/docs-themeDavid Lordbefore adoption19a0a7d
line 65why, one step back65def github_link(name, rawtext, text, lineno, inliner, options=None, content=None):Merge pull request #2707 from rochacbruno/lazy_loader_messageDavid Lordbefore adoptione102e5c
lines 66–67why, one step back66 app = inliner.document.settings.env.app67 release = app.config.releaseMerge pull request #2912 from pallets/docs-themeDavid Lordbefore adoption19a0a7d
line 68why, one step back68 base_url = "https://github.com/pallets/flask/tree/"Merge pull request #2707 from rochacbruno/lazy_loader_messageDavid Lordbefore adoptione102e5c
line 69why, one step back69Merge pull request #2912 from pallets/docs-themeDavid Lordbefore adoption19a0a7d
lines 70–71why, one step back70 if text.endswith(">"):71 words, text = text[:-1].rsplit("<", 1)Merge pull request #2707 from rochacbruno/lazy_loader_messageDavid Lordbefore adoptione102e5c
lines 72–75why, one step back72 words = words.strip()73 else:74 words = None75Merge branch '1.1.x'David Lordbefore adoption0adbaf2
line 76why, one step back76 if packaging.version.parse(release).is_devrelease:Merge pull request #3554 from pallets/drop-python2David Lordbefore adoptioncd8a374
line 77why, one step back77 url = f"{base_url}master/{text}"Merge pull request #2707 from rochacbruno/lazy_loader_messageDavid Lordbefore adoptione102e5c
line 78why, one step back78 else:Merge pull request #3554 from pallets/drop-python2David Lordbefore adoptioncd8a374
line 79why, one step back79 url = f"{base_url}{release}/{text}"Merge pull request #2707 from rochacbruno/lazy_loader_messageDavid Lordbefore adoptione102e5c
lines 80–85why, one step back8081 if words is None:82 words = url8384 from docutils.nodes import reference85 from docutils.parsers.rst.roles import set_classesMerge pull request #2912 from pallets/docs-themeDavid Lordbefore adoption19a0a7d
line 86why, one step back86Merge pull request #2707 from rochacbruno/lazy_loader_messageDavid Lordbefore adoptione102e5c
lines 87–93why, one step back87 options = options or {}88 set_classes(options)89 node = reference(rawtext, words, refuri=url, **options)90 return [node], []919293def setup(app):Merge pull request #2912 from pallets/docs-themeDavid Lordbefore adoption19a0a7d
line 94why, one step back94 app.add_role("gh", github_link)