summaryrefslogtreecommitdiff
path: root/sphinx/quickstart.py
diff options
context:
space:
mode:
authoranatoly techtonik <techtonik@gmail.com>2012-11-03 19:21:07 +0300
committeranatoly techtonik <techtonik@gmail.com>2012-11-03 19:21:07 +0300
commit621270c2e032c0ccbe542473d85024115d1c2fc3 (patch)
tree46eaa4349f3a8d5bcfc90224a9e549adf4d4e75b /sphinx/quickstart.py
parentd80c828be2bb5d1a6c8569043301f8a57c5c1c06 (diff)
downloadsphinx-621270c2e032c0ccbe542473d85024115d1c2fc3.tar.gz
make.bat: improve error message if Sphinx is not found
Diffstat (limited to 'sphinx/quickstart.py')
-rw-r--r--sphinx/quickstart.py14
1 files changed, 14 insertions, 0 deletions
diff --git a/sphinx/quickstart.py b/sphinx/quickstart.py
index 3adccdec..0bb3a192 100644
--- a/sphinx/quickstart.py
+++ b/sphinx/quickstart.py
@@ -581,6 +581,20 @@ if "%%1" == "clean" (
\tgoto end
)
+
+%%SPHINXBUILD%% 2> nul
+if errorlevel 9009 (
+ echo.
+ echo.The 'sphinx-build' command was not found. Make sure Sphinx is
+ echo.installed, then set the SPHINXBUILD environment variable to point
+ echo.to the full path of the 'sphinx-build' executable. Alternatively
+ echo.you may add the Sphinx directory to PATH.
+ echo.
+ echo.If you don't have Sphinx installed, grab it from
+ echo.http://sphinx.pocoo.org/
+ exit /b 1
+)
+
if "%%1" == "html" (
\t%%SPHINXBUILD%% -b html %%ALLSPHINXOPTS%% %%BUILDDIR%%/html
\tif errorlevel 1 exit /b 1