From 0a1390a7f673f96fb395c1b964087b8b61ef3655 Mon Sep 17 00:00:00 2001 From: pagedown Date: Sat, 11 Dec 2021 23:02:53 +0800 Subject: [PATCH] Docs: Enable kbd transform when building dirhtml with sphinx --- docs/conf.py | 3 +++ 1 file changed, 3 insertions(+) diff --git a/docs/conf.py b/docs/conf.py index 479b29e30..19c614c71 100644 --- a/docs/conf.py +++ b/docs/conf.py @@ -22,8 +22,11 @@ from pygments.token import ( # type: ignore Comment, Keyword, Literal, Name, Number, String, Whitespace ) from sphinx import addnodes, version_info # type: ignore +from sphinx.builders.html.transforms import KeyboardTransform # type: ignore from sphinx.util.logging import getLogger # type: ignore +KeyboardTransform.builders = ('html', 'dirhtml') # type: ignore + kitty_src = os.path.dirname(os.path.dirname(os.path.abspath(__file__))) if kitty_src not in sys.path: sys.path.insert(0, kitty_src)