File tree Expand file tree Collapse file tree 1 file changed +5
-2
lines changed
Expand file tree Collapse file tree 1 file changed +5
-2
lines changed Original file line number Diff line number Diff line change 1010from importlib .metadata import version
1111from pathlib import Path
1212
13+ from sphinx .application import Sphinx
14+
1315from docs .source .docs_utils .tutorials import generate_tutorial_links_for_notebook_creation
1416
1517conf_dir = os .path .dirname (os .path .abspath (__file__ )) # noqa: PTH100, PTH120
164166repo_root = Path (__file__ ).resolve ().parents [2 ] # if conf.py is in docs/
165167
166168
167- def setup (app ) -> None : # noqa: ANN001
169+ def setup (app : Sphinx ) -> None :
168170 generate_versions_json (repo_root , BASE_URL )
171+ user_guids_dir = app .srcdir / "docs" / "source" / "user_guides"
169172
170173 generate_tutorial_links_for_notebook_creation (
171174 include = [
@@ -180,6 +183,6 @@ def setup(app) -> None: # noqa: ANN001
180183 ("user_guides.cli" , "CLI Usage" ),
181184 ],
182185 source = "user_guides" ,
183- destination = "docs/source/user_guides" ,
186+ destination = user_guids_dir ,
184187 )
185188 app .connect ("autoapi-skip-member" , skip_member )
You can’t perform that action at this time.
0 commit comments