mirror of
https://github.com/ChristianLight/tutor.git
synced 2025-01-10 09:02:14 +00:00
eb0660a55a
Address several security issues raised by Dependabot.
16 lines
444 B
Python
16 lines
444 B
Python
"""
|
|
This module is heavily inspired by Django's djangodocs.py:
|
|
https://github.com/django/django/blob/main/docs/_ext/djangodocs.py
|
|
"""
|
|
|
|
from sphinx.application import Sphinx
|
|
|
|
|
|
def setup(app: Sphinx) -> None:
|
|
# https://www.sphinx-doc.org/en/master/extdev/appapi.html#sphinx.application.Sphinx.add_crossref_type
|
|
app.add_crossref_type(
|
|
directivename="patch",
|
|
rolename="patch",
|
|
indextemplate="pair: %s; patch",
|
|
)
|