diff --git a/.gitignore b/.gitignore index 4c0a1cd..2668047 100644 --- a/.gitignore +++ b/.gitignore @@ -27,11 +27,15 @@ htmlcov/ # Sphinx build output docs/_build/ +docs/api/generated/ +docs/auto_examples/ +docs/sg_execution_times.rst build/html/ build/doctrees/ # Generated Pyodide wheel (built by workflow / make html — never commit) docs/_static/wheels/ +docs/_static/anywidget_config.js # Editor / IDE .idea/ @@ -41,5 +45,3 @@ docs/_static/wheels/ # macOS .DS_Store - - diff --git a/Makefile b/Makefile index b97de95..0005703 100644 --- a/Makefile +++ b/Makefile @@ -18,3 +18,8 @@ help: # "make mode" option. $(O) is meant as a shortcut for $(SPHINXOPTS). %: Makefile @$(SPHINXBUILD) -M $@ "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O) + +clean: + rm -rf $(BUILDDIR)/* + rm -rf docs/auto_examples/ + rm -rf docs/api/generated/ diff --git a/make.bat b/make.bat index dc1312a..0917349 100644 --- a/make.bat +++ b/make.bat @@ -7,7 +7,7 @@ REM Command file for Sphinx documentation if "%SPHINXBUILD%" == "" ( set SPHINXBUILD=sphinx-build ) -set SOURCEDIR=source +set SOURCEDIR=docs set BUILDDIR=build %SPHINXBUILD% >NUL 2>NUL @@ -23,6 +23,15 @@ if errorlevel 9009 ( exit /b 1 ) +if "%1" == "clean" ( + for /d %%i in (%BUILDDIR%\*) do rmdir /q /s %%i + del /q /s %BUILDDIR%\* + rmdir /q /s docs\api\generated + rmdir /q /s docs\auto_examples + goto end +) + + if "%1" == "" goto help %SPHINXBUILD% -M %1 %SOURCEDIR% %BUILDDIR% %SPHINXOPTS% %O%