mirror of
https://github.com/curl/curl.git
synced 2025-02-11 14:50:40 +08:00
generate.bat: Added a check for the presence of a git repository
This commit is contained in:
parent
3f5f042e5d
commit
0342ada31f
@ -38,6 +38,9 @@ rem If you need to set the errorlevel do this instead: CALL :seterr [#]
|
|||||||
rem Switch to this batch file's directory
|
rem Switch to this batch file's directory
|
||||||
cd /d "%~0\.." 1>NUL 2>&1
|
cd /d "%~0\.." 1>NUL 2>&1
|
||||||
|
|
||||||
|
rem Check we are running from a curl git repository
|
||||||
|
if not exist ..\GIT-INFO goto norepo
|
||||||
|
|
||||||
rem Set our variables
|
rem Set our variables
|
||||||
setlocal ENABLEEXTENSIONS
|
setlocal ENABLEEXTENSIONS
|
||||||
set VERSION=ALL
|
set VERSION=ALL
|
||||||
@ -483,6 +486,11 @@ rem Returns exit code 0 on success or 1 on failure.
|
|||||||
echo Error: This batch file cannot run from a network drive
|
echo Error: This batch file cannot run from a network drive
|
||||||
goto error
|
goto error
|
||||||
|
|
||||||
|
:norepo
|
||||||
|
echo.
|
||||||
|
echo Error: This batch file should only be used from a curl git repository
|
||||||
|
goto error
|
||||||
|
|
||||||
:nogencurlbuild
|
:nogencurlbuild
|
||||||
echo.
|
echo.
|
||||||
echo Error: Unable to generate ..\include\curl\curlbuild.h
|
echo Error: Unable to generate ..\include\curl\curlbuild.h
|
||||||
|
Loading…
Reference in New Issue
Block a user