diff options
| author | Anderson Bravalheri <andersonbravalheri@gmail.com> | 2022-01-06 16:17:31 +0000 |
|---|---|---|
| committer | Anderson Bravalheri <andersonbravalheri@gmail.com> | 2022-01-06 16:17:31 +0000 |
| commit | 6cff3789dd3cfb06b504cf42714c6ed6936cb23f (patch) | |
| tree | 22602a79fad718e5bdbb9bc8d774e9b75c4c0f04 /docs/conf.py | |
| parent | 5c7a84c63ae1d7f93d8cc0008311d47906a24117 (diff) | |
| download | python-setuptools-git-6cff3789dd3cfb06b504cf42714c6ed6936cb23f.tar.gz | |
Replace in-tree sphinx extension with sphinx-favicon
This change has been previously proposed and agreed upon in #2869.
The idea here is to avoid the burden of maintaining an in-tree sphinx
extension, now that `sphinx-favicon` is available and covers setuptools
use-case.
Diffstat (limited to 'docs/conf.py')
| -rw-r--r-- | docs/conf.py | 13 |
1 files changed, 6 insertions, 7 deletions
diff --git a/docs/conf.py b/docs/conf.py index f6ccff0f..4a14214f 100644 --- a/docs/conf.py +++ b/docs/conf.py @@ -179,23 +179,22 @@ towncrier_draft_include_empty = False extensions += ['jaraco.tidelift'] # Add icons (aka "favicons") to documentation -sys.path.append(os.path.join(os.path.dirname(__file__), '_ext')) -extensions += ['_custom_icons'] +extensions += ['sphinx-favicon'] +html_static_path = ['images'] # should contain the folder with icons # List of dicts with <link> HTML attributes -# as defined in https://developer.mozilla.org/en-US/docs/Web/HTML/Element/link -# except that ``file`` gets replaced with the correct ``href`` -icons = [ +# static-file points to files in the html_static_path (href is computed) +favicons = [ { # "Catch-all" goes first, otherwise some browsers will overwrite "rel": "icon", "type": "image/svg+xml", - "file": "images/logo-symbol-only.svg", + "static-file": "logo-symbol-only.svg", "sizes": "any" }, { # Version with thicker strokes for better visibility at smaller sizes "rel": "icon", "type": "image/svg+xml", - "file": "images/favicon.svg", + "static-file": "favicon.svg", "sizes": "16x16 24x24 32x32 48x48" }, # rel="apple-touch-icon" does not support SVG yet |
