make.bat 1.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354
  1. REM Licensed to the Apache Software Foundation (ASF) under one
  2. REM or more contributor license agreements. See the NOTICE file
  3. REM distributed with this work for additional information
  4. REM regarding copyright ownership. The ASF licenses this file
  5. REM to you under the Apache License, Version 2.0 (the
  6. REM "License"); you may not use this file except in compliance
  7. REM with the License. You may obtain a copy of the License at
  8. REM
  9. REM http://www.apache.org/licenses/LICENSE-2.0
  10. REM
  11. REM Unless required by applicable law or agreed to in writing,
  12. REM software distributed under the License is distributed on an
  13. REM "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
  14. REM KIND, either express or implied. See the License for the
  15. REM specific language governing permissions and limitations
  16. REM under the License.
  17. @ECHO OFF
  18. pushd %~dp0
  19. REM Command file for Sphinx documentation
  20. if "%SPHINXBUILD%" == "" (
  21. set SPHINXBUILD=sphinx-build
  22. )
  23. set SOURCEDIR=source
  24. set BUILDDIR=build
  25. REM Add opts `turn warnings into errors` strict sphinx-build behavior
  26. set SPHINXOPTS=-W
  27. if "%1" == "" goto help
  28. %SPHINXBUILD% >NUL 2>NUL
  29. if errorlevel 9009 (
  30. echo.
  31. echo.The 'sphinx-build' command was not found. Make sure you have Sphinx
  32. echo.installed, then set the SPHINXBUILD environment variable to point
  33. echo.to the full path of the 'sphinx-build' executable. Alternatively you
  34. echo.may add the Sphinx directory to PATH.
  35. echo.
  36. echo.If you don't have Sphinx installed, grab it from
  37. echo.https://www.sphinx-doc.org/
  38. exit /b 1
  39. )
  40. %SPHINXBUILD% -M %1 %SOURCEDIR% %BUILDDIR% %SPHINXOPTS% %O%
  41. goto end
  42. :help
  43. %SPHINXBUILD% -M help %SOURCEDIR% %BUILDDIR% %SPHINXOPTS% %O%
  44. :end
  45. popd