1 Debian patch touch this file
-
Removed sphinx ext.intersphinx to avoid network access
- Author
- Josenilson Ferreira da Silva <[email protected]>
- Forwarded
- not-needed
| 1 | # Configuration file for the Sphinx documentation builder. |
| 2 | # |
| 3 | # This file only contains a selection of the most common options. For a full |
| 4 | # list see the documentation: |
| 5 | # https://www.sphinx-doc.org/en/master/usage/configuration.html |
| 6 | |
| 7 | # -- Path setup -------------------------------------------------------------- |
| 8 | |
| 9 | # If extensions (or modules to document with autodoc) are in another directory, |
| 10 | # add these directories to sys.path here. If the directory is relative to the |
| 11 | # documentation root, use os.path.abspath to make it absolute, like shown here. |
| 12 | # |
| 13 | # import os |
| 14 | # import sys |
| 15 | # sys.path.insert(0, os.path.abspath('.')) |
| 16 | |
| 17 | import re |
| 18 | |
| 19 | # -- Project information ----------------------------------------------------- |
| 20 | |
| 21 | project = 'rich-rst' |
| 22 | copyright = '2022, Wasi Master aka. Arian Mollik Wasi' |
| 23 | author = 'Wasi Master aka. Arian Mollik Wasi' |
| 24 | |
| 25 | # The full version, including alpha/beta/rc tags |
| 26 | version = '' |
| 27 | with open('../../rich_rst/__init__.py', encoding="utf-8") as f: |
| 28 | version = re.search(r'^__version__\s*=\s*[\'"]([^\'"]*)[\'"]', f.read(), re.MULTILINE).group(1) |
| 29 | |
| 30 | # -- General configuration --------------------------------------------------- |
| 31 | |
| 32 | # Add any Sphinx extension module names here, as strings. They can be |
| 33 | # extensions coming with Sphinx (named 'sphinx.ext.*') or your custom |
| 34 | # ones. |
| 35 | extensions = [ |
| 36 | 'sphinx.ext.autodoc', |
| 37 | 'sphinx.ext.viewcode', |
| 38 | 'sphinx.ext.napoleon', |
| 39 | 'sphinx_copybutton', |
| 40 | ] |
| 41 | |
| 42 | # Add the locations and names of other projects that should be linked to in this documentation. |
| 43 | intersphinx_mapping = {'python': ('https://docs.python.org/3', None), 'rich': ('https://rich.readthedocs.io/en/stable/', None)} |
| 44 | |
| 45 | # Add any paths that contain templates here, relative to this directory. |
| 46 | templates_path = ['_templates'] |
| 47 | |
| 48 | # List of patterns, relative to source directory, that match files and |
| 49 | # directories to ignore when looking for source files. |
| 50 | # This pattern also affects html_static_path and html_extra_path. |
| 51 | exclude_patterns = [] |
| 52 | |
| 53 | # For readthedocs |
| 54 | master_doc = 'index' |
| 55 | |
| 56 | # -- Options for HTML output ------------------------------------------------- |
| 57 | |
| 58 | # The theme to use for HTML and HTML Help pages. See the documentation for |
| 59 | # a list of builtin themes. |
| 60 | # |
| 61 | # html_theme = 'sphinxawesome_theme' |
| 62 | html_theme = 'sphinx_rtd_theme' |
| 63 | |
| 64 | # Add any paths that contain custom static files (such as style sheets) here, |
| 65 | # relative to this directory. They are copied after the builtin static files, |
| 66 | # so a file named "default.css" will overwrite the builtin "default.css". |
| 67 | html_static_path = ['_static'] |
| 68 | # Add any files that contain extra static files that will be placed in the |
| 69 | # document root. They are copied after the builtin static files and will |
| 70 | # overwrite the builtin files |
| 71 | html_extra_path = ['_extra'] |
| 72 | # Add any files that contain extra custom css |
| 73 | html_css_files = ["custom.css"] |
| 74 | |
| 75 | # Config for sphinxawesome_theme |
| 76 | # html_permalinks_icon = '<span>#</span>' |
| 77 | # html_collapsible_definitions = True |
| 78 | # html_theme_options = { |
| 79 | # "show_prev_next": True, |
| 80 | # "show_scrolltop": True, |
| 81 | # "extra_header_links": { |
| 82 | # "Docs": "./docs", |
| 83 | # "Demo": "./demo", |
| 84 | # } |
| 85 | # } |
| 86 | |
| 87 | html_theme_options = { |
| 88 | 'display_version': True, |
| 89 | } |
| 90 | html_context = { |
| 91 | "display_github": True, # Add 'Edit on Github' link instead of 'View page source' |
| 92 | "github_user": "wasi-master", |
| 93 | "github_repo": project, |
| 94 | "github_version": "main", |
| 95 | "conf_py_path": "/docs/source/", |
| •96 | } |