import os import sys import sccd sys.path.insert(0, os.path.abspath("..")) html_favicon = "static/images/docs_logo.svg" supported_languages = { "en": "SCCD (%s) documentation in English", } extensions = [ "notfound.extension", "recommonmark", "sphinx.ext.autodoc", "sphinx.ext.viewcode", "sphinx_rtd_theme", "sphinx_search.extension", "sphinx_tabs.tabs", "sphinxext.opengraph", # "sphinx.ext.autosectionlabel", ] # autosectionlabel_prefix_document = True sphinx_tabs_nowarn = True templates_path = ["templates"] source_suffix = { ".rst": "restructuredtext", ".txt": "markdown", ".md": "markdown", } source_encoding = "utf-8-sig" master_doc = "index" project = "sccd" copyright = "2021, Arkadiusz Michał Ryś" author = "Arkadiusz Michał Ryś" version = sccd.__version__ release = sccd.__version__ ogp_site_name = "SCCD documentation" env_tags = os.getenv("SPHINX_TAGS") if env_tags is not None: for tag in env_tags.split(","): print("Adding Sphinx tag: %s" % tag.strip()) tags.add(tag.strip()) # noqa: F821 language = os.getenv("READTHEDOCS_LANGUAGE", "en") if language not in supported_languages.keys(): print("Unknown language: " + language) print("Supported languages: " + ", ".join(supported_languages.keys())) print("The configured language is wrong. Falling back to 'en'.") language = "en" exclude_patterns = ["_build", "Thumbs.db", ".DS_Store", "examples", "notations"] pygments_style = "sphinx" todo_include_todos = False html_theme = "sphinx_rtd_theme" html_theme_options = { "logo_only": True, "collapse_navigation": False, } html_logo = "static/images/docs_logo.svg" html_static_path = ["static"] htmlhelp_basename = "sccddoc" html_extra_path = ["robots.txt"] html_css_files = ["css/custom.css"] html_js_files = ["js/custom.js"] on_rtd = os.environ.get("READTHEDOCS", None) == "True" html_title = supported_languages[language] % version html_context = {"conf_py_path": "/"} latex_engine = "pdflatex" latex_elements = { "papersize": "letterpaper", "pointsize": "10pt", "figure_align": "htbp", } latex_documents = [ ( master_doc, "sccd.tex", "SCCD Documentation", "Arkadiusz Michał Ryś", "manual" ), ] man_pages = [( master_doc, "sccd", "SCCD Documentation", [author], 1 )] texinfo_documents = [( master_doc, "sccd", "SCCD Documentation", author, "sccd", "Distributed spreadsheet application.", "Miscellaneous" )] notfound_context = { "title": "Page not found", "body": """
Sorry, we couldn't find that page. It may have been renamed or removed in the version of the documentation you're currently browsing.
If you're currently browsing the latest version of the documentation, try browsing the stable version of the documentation.
Alternatively, use the Search docs box on the left or go to the homepage.
""", }