summaryrefslogtreecommitdiff
path: root/sphinx/ext/githubpages.py
diff options
context:
space:
mode:
Diffstat (limited to 'sphinx/ext/githubpages.py')
-rw-r--r--sphinx/ext/githubpages.py8
1 files changed, 8 insertions, 0 deletions
diff --git a/sphinx/ext/githubpages.py b/sphinx/ext/githubpages.py
index b267b1740..f97c810f8 100644
--- a/sphinx/ext/githubpages.py
+++ b/sphinx/ext/githubpages.py
@@ -10,16 +10,24 @@
"""
import os
+from typing import TYPE_CHECKING
import sphinx
+if TYPE_CHECKING:
+ from typing import Any, Dict # NOQA
+ from sphinx.application import Sphinx # NOQA
+ from sphinx.environment import BuildEnvironment # NOQA
+
def create_nojekyll(app, env):
+ # type: (Sphinx, BuildEnvironment) -> None
if app.builder.format == 'html':
path = os.path.join(app.builder.outdir, '.nojekyll')
open(path, 'wt').close()
def setup(app):
+ # type: (Sphinx) -> Dict[unicode, Any]
app.connect('env-updated', create_nojekyll)
return {'version': sphinx.__display_version__, 'parallel_read_safe': True}