@@ -15,54 +15,28 @@ extras =
1515 testing
1616commands = pytest {posargs}
1717
18- [testenv:docs-{update,clean}-{ alabaster,rtd,pydata,sbt,furo}]
18+ [testenv:docs-{alabaster,rtd,pydata,sbt,furo}]
1919description =
20- clean: Run documentation build for this theme (removing existing builds)
21- update: Run documentation build for this theme (reusing existing builds)
20+ Run documentation build for this theme
2221extras =
2322 rtd
2423 rtd: theme_rtd
2524 pydata: theme_pydata
2625 sbt: theme_sbt
2726 furo: theme_furo
28- allowlist_externals =
29- clean: rm
30- echo
27+ allowlist_externals = echo
28+ passenv =
29+ BUILDER
30+ CLEAN
31+ TERM
3132setenv =
32- update: SKIP_APIDOC = true
3333 alabaster: SPHINX_THEME = alabaster
3434 rtd: SPHINX_THEME = sphinx_rtd_theme
3535 pydata: SPHINX_THEME = pydata_sphinx_theme
3636 sbt: SPHINX_THEME = sphinx_book_theme
3737 furo: SPHINX_THEME = furo
38+ commands_pre =
39+ python -c " import shutil; shutil.rmtree('docs/_build/{env:BUILDER:html}/{env:SPHINX_THEME:}', ignore_errors=True) if '{env:CLEAN:}' else None"
3840commands =
39- clean: rm -rf docs/_build/{posargs:html}
40- sphinx-build -nW --keep-going -b {posargs:html} docs/ docs/_build/{posargs:html}
41- commands_post = echo " open docs/_build/{posargs:html}/index.html"
42-
43- [testenv:docs-live-{alabaster,rtd,pydata,sbt,furo}]
44- description = Start documentation autobuild for this theme
45- extras =
46- rtd
47- rtd: theme_rtd
48- pydata: theme_pydata
49- sbt: theme_sbt
50- furo: theme_furo
51- deps =
52- pre-commit
53- sphinx-autobuild
54- setenv =
55- alabaster: SPHINX_THEME = alabaster
56- rtd: SPHINX_THEME = sphinx_rtd_theme
57- pydata: SPHINX_THEME = pydata_sphinx_theme
58- sbt: SPHINX_THEME = sphinx_book_theme
59- furo: SPHINX_THEME = furo
60- commands =
61- sphinx-autobuild \
62- --watch sphinx_design \
63- --watch style \
64- --pre-build " npm run css" \
65- --re-ignore sphinx_design/compiled/.* \
66- --re-ignore docs/_build/.* \
67- --port 0 --open-browser \
68- -n -b {posargs:html} docs/ docs/_build/{posargs:html}
41+ sphinx-build -nW --keep-going {posargs} -b {env:BUILDER:html} docs/ docs/_build/{env:BUILDER:html}/{env:SPHINX_THEME:}
42+ commands_post = echo " open docs/_build//{env:BUILDER:html}/{env:SPHINX_THEME:}/index.html"
0 commit comments