Slightly better python-finding.
This commit is contained in:
parent
3b7002e945
commit
880835d9b5
7
xb.bat
7
xb.bat
|
@ -36,16 +36,15 @@ IF NOT ERRORLEVEL 1 (
|
||||||
ECHO FOUND PYTHON 2
|
ECHO FOUND PYTHON 2
|
||||||
SET FOUND_PYTHON_EXE=python2
|
SET FOUND_PYTHON_EXE=python2
|
||||||
)
|
)
|
||||||
|
IF %FOUND_PYTHON_EXE% EQU "" (
|
||||||
|
IF EXIST c:\\python27\\python.exe SET FOUND_PYTHON_EXE=C:\\python27\\python.exe
|
||||||
|
)
|
||||||
IF %FOUND_PYTHON_EXE% EQU "" (
|
IF %FOUND_PYTHON_EXE% EQU "" (
|
||||||
1>NUL 2>NUL CMD /c where python
|
1>NUL 2>NUL CMD /c where python
|
||||||
IF NOT ERRORLEVEL 1 (
|
IF NOT ERRORLEVEL 1 (
|
||||||
SET FOUND_PYTHON_EXE=python
|
SET FOUND_PYTHON_EXE=python
|
||||||
)
|
)
|
||||||
)
|
)
|
||||||
IF %FOUND_PYTHON_EXE% EQU "" (
|
|
||||||
ECHO Found from fs
|
|
||||||
IF EXIST c:\python27\python.exe SET FOUND_PYTHON_EXE=C:\python27\python.exe
|
|
||||||
)
|
|
||||||
IF %FOUND_PYTHON_EXE% EQU "" (
|
IF %FOUND_PYTHON_EXE% EQU "" (
|
||||||
ECHO ERROR: no Python executable found on PATH.
|
ECHO ERROR: no Python executable found on PATH.
|
||||||
ECHO Make sure you can run 'python' or 'python2' in a Command Prompt.
|
ECHO Make sure you can run 'python' or 'python2' in a Command Prompt.
|
||||||
|
|
Loading…
Reference in New Issue