gradlew.bat
author Da Risk <da_risk@geekorum.com>
Sat, 24 Nov 2018 17:54:27 -0800
changeset 0 14443efede32
child 1360 fc435d5de38c
permissions -rw-r--r--
Initial commit
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
0
14443efede32 Initial commit
Da Risk <da_risk@geekorum.com>
parents:
diff changeset
     1
@if "%DEBUG%" == "" @echo off
14443efede32 Initial commit
Da Risk <da_risk@geekorum.com>
parents:
diff changeset
     2
@rem ##########################################################################
14443efede32 Initial commit
Da Risk <da_risk@geekorum.com>
parents:
diff changeset
     3
@rem
14443efede32 Initial commit
Da Risk <da_risk@geekorum.com>
parents:
diff changeset
     4
@rem  Gradle startup script for Windows
14443efede32 Initial commit
Da Risk <da_risk@geekorum.com>
parents:
diff changeset
     5
@rem
14443efede32 Initial commit
Da Risk <da_risk@geekorum.com>
parents:
diff changeset
     6
@rem ##########################################################################
14443efede32 Initial commit
Da Risk <da_risk@geekorum.com>
parents:
diff changeset
     7
14443efede32 Initial commit
Da Risk <da_risk@geekorum.com>
parents:
diff changeset
     8
@rem Set local scope for the variables with windows NT shell
14443efede32 Initial commit
Da Risk <da_risk@geekorum.com>
parents:
diff changeset
     9
if "%OS%"=="Windows_NT" setlocal
14443efede32 Initial commit
Da Risk <da_risk@geekorum.com>
parents:
diff changeset
    10
14443efede32 Initial commit
Da Risk <da_risk@geekorum.com>
parents:
diff changeset
    11
set DIRNAME=%~dp0
14443efede32 Initial commit
Da Risk <da_risk@geekorum.com>
parents:
diff changeset
    12
if "%DIRNAME%" == "" set DIRNAME=.
14443efede32 Initial commit
Da Risk <da_risk@geekorum.com>
parents:
diff changeset
    13
set APP_BASE_NAME=%~n0
14443efede32 Initial commit
Da Risk <da_risk@geekorum.com>
parents:
diff changeset
    14
set APP_HOME=%DIRNAME%
14443efede32 Initial commit
Da Risk <da_risk@geekorum.com>
parents:
diff changeset
    15
14443efede32 Initial commit
Da Risk <da_risk@geekorum.com>
parents:
diff changeset
    16
@rem Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script.
14443efede32 Initial commit
Da Risk <da_risk@geekorum.com>
parents:
diff changeset
    17
set DEFAULT_JVM_OPTS=
14443efede32 Initial commit
Da Risk <da_risk@geekorum.com>
parents:
diff changeset
    18
14443efede32 Initial commit
Da Risk <da_risk@geekorum.com>
parents:
diff changeset
    19
@rem Find java.exe
14443efede32 Initial commit
Da Risk <da_risk@geekorum.com>
parents:
diff changeset
    20
if defined JAVA_HOME goto findJavaFromJavaHome
14443efede32 Initial commit
Da Risk <da_risk@geekorum.com>
parents:
diff changeset
    21
14443efede32 Initial commit
Da Risk <da_risk@geekorum.com>
parents:
diff changeset
    22
set JAVA_EXE=java.exe
14443efede32 Initial commit
Da Risk <da_risk@geekorum.com>
parents:
diff changeset
    23
%JAVA_EXE% -version >NUL 2>&1
14443efede32 Initial commit
Da Risk <da_risk@geekorum.com>
parents:
diff changeset
    24
if "%ERRORLEVEL%" == "0" goto init
14443efede32 Initial commit
Da Risk <da_risk@geekorum.com>
parents:
diff changeset
    25
14443efede32 Initial commit
Da Risk <da_risk@geekorum.com>
parents:
diff changeset
    26
echo.
14443efede32 Initial commit
Da Risk <da_risk@geekorum.com>
parents:
diff changeset
    27
echo ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH.
14443efede32 Initial commit
Da Risk <da_risk@geekorum.com>
parents:
diff changeset
    28
echo.
14443efede32 Initial commit
Da Risk <da_risk@geekorum.com>
parents:
diff changeset
    29
echo Please set the JAVA_HOME variable in your environment to match the
14443efede32 Initial commit
Da Risk <da_risk@geekorum.com>
parents:
diff changeset
    30
echo location of your Java installation.
14443efede32 Initial commit
Da Risk <da_risk@geekorum.com>
parents:
diff changeset
    31
14443efede32 Initial commit
Da Risk <da_risk@geekorum.com>
parents:
diff changeset
    32
goto fail
14443efede32 Initial commit
Da Risk <da_risk@geekorum.com>
parents:
diff changeset
    33
14443efede32 Initial commit
Da Risk <da_risk@geekorum.com>
parents:
diff changeset
    34
:findJavaFromJavaHome
14443efede32 Initial commit
Da Risk <da_risk@geekorum.com>
parents:
diff changeset
    35
set JAVA_HOME=%JAVA_HOME:"=%
14443efede32 Initial commit
Da Risk <da_risk@geekorum.com>
parents:
diff changeset
    36
set JAVA_EXE=%JAVA_HOME%/bin/java.exe
14443efede32 Initial commit
Da Risk <da_risk@geekorum.com>
parents:
diff changeset
    37
14443efede32 Initial commit
Da Risk <da_risk@geekorum.com>
parents:
diff changeset
    38
if exist "%JAVA_EXE%" goto init
14443efede32 Initial commit
Da Risk <da_risk@geekorum.com>
parents:
diff changeset
    39
14443efede32 Initial commit
Da Risk <da_risk@geekorum.com>
parents:
diff changeset
    40
echo.
14443efede32 Initial commit
Da Risk <da_risk@geekorum.com>
parents:
diff changeset
    41
echo ERROR: JAVA_HOME is set to an invalid directory: %JAVA_HOME%
14443efede32 Initial commit
Da Risk <da_risk@geekorum.com>
parents:
diff changeset
    42
echo.
14443efede32 Initial commit
Da Risk <da_risk@geekorum.com>
parents:
diff changeset
    43
echo Please set the JAVA_HOME variable in your environment to match the
14443efede32 Initial commit
Da Risk <da_risk@geekorum.com>
parents:
diff changeset
    44
echo location of your Java installation.
14443efede32 Initial commit
Da Risk <da_risk@geekorum.com>
parents:
diff changeset
    45
14443efede32 Initial commit
Da Risk <da_risk@geekorum.com>
parents:
diff changeset
    46
goto fail
14443efede32 Initial commit
Da Risk <da_risk@geekorum.com>
parents:
diff changeset
    47
14443efede32 Initial commit
Da Risk <da_risk@geekorum.com>
parents:
diff changeset
    48
:init
14443efede32 Initial commit
Da Risk <da_risk@geekorum.com>
parents:
diff changeset
    49
@rem Get command-line arguments, handling Windows variants
14443efede32 Initial commit
Da Risk <da_risk@geekorum.com>
parents:
diff changeset
    50
14443efede32 Initial commit
Da Risk <da_risk@geekorum.com>
parents:
diff changeset
    51
if not "%OS%" == "Windows_NT" goto win9xME_args
14443efede32 Initial commit
Da Risk <da_risk@geekorum.com>
parents:
diff changeset
    52
14443efede32 Initial commit
Da Risk <da_risk@geekorum.com>
parents:
diff changeset
    53
:win9xME_args
14443efede32 Initial commit
Da Risk <da_risk@geekorum.com>
parents:
diff changeset
    54
@rem Slurp the command line arguments.
14443efede32 Initial commit
Da Risk <da_risk@geekorum.com>
parents:
diff changeset
    55
set CMD_LINE_ARGS=
14443efede32 Initial commit
Da Risk <da_risk@geekorum.com>
parents:
diff changeset
    56
set _SKIP=2
14443efede32 Initial commit
Da Risk <da_risk@geekorum.com>
parents:
diff changeset
    57
14443efede32 Initial commit
Da Risk <da_risk@geekorum.com>
parents:
diff changeset
    58
:win9xME_args_slurp
14443efede32 Initial commit
Da Risk <da_risk@geekorum.com>
parents:
diff changeset
    59
if "x%~1" == "x" goto execute
14443efede32 Initial commit
Da Risk <da_risk@geekorum.com>
parents:
diff changeset
    60
14443efede32 Initial commit
Da Risk <da_risk@geekorum.com>
parents:
diff changeset
    61
set CMD_LINE_ARGS=%*
14443efede32 Initial commit
Da Risk <da_risk@geekorum.com>
parents:
diff changeset
    62
14443efede32 Initial commit
Da Risk <da_risk@geekorum.com>
parents:
diff changeset
    63
:execute
14443efede32 Initial commit
Da Risk <da_risk@geekorum.com>
parents:
diff changeset
    64
@rem Setup the command line
14443efede32 Initial commit
Da Risk <da_risk@geekorum.com>
parents:
diff changeset
    65
14443efede32 Initial commit
Da Risk <da_risk@geekorum.com>
parents:
diff changeset
    66
set CLASSPATH=%APP_HOME%\gradle\wrapper\gradle-wrapper.jar
14443efede32 Initial commit
Da Risk <da_risk@geekorum.com>
parents:
diff changeset
    67
14443efede32 Initial commit
Da Risk <da_risk@geekorum.com>
parents:
diff changeset
    68
@rem Execute Gradle
14443efede32 Initial commit
Da Risk <da_risk@geekorum.com>
parents:
diff changeset
    69
"%JAVA_EXE%" %DEFAULT_JVM_OPTS% %JAVA_OPTS% %GRADLE_OPTS% "-Dorg.gradle.appname=%APP_BASE_NAME%" -classpath "%CLASSPATH%" org.gradle.wrapper.GradleWrapperMain %CMD_LINE_ARGS%
14443efede32 Initial commit
Da Risk <da_risk@geekorum.com>
parents:
diff changeset
    70
14443efede32 Initial commit
Da Risk <da_risk@geekorum.com>
parents:
diff changeset
    71
:end
14443efede32 Initial commit
Da Risk <da_risk@geekorum.com>
parents:
diff changeset
    72
@rem End local scope for the variables with windows NT shell
14443efede32 Initial commit
Da Risk <da_risk@geekorum.com>
parents:
diff changeset
    73
if "%ERRORLEVEL%"=="0" goto mainEnd
14443efede32 Initial commit
Da Risk <da_risk@geekorum.com>
parents:
diff changeset
    74
14443efede32 Initial commit
Da Risk <da_risk@geekorum.com>
parents:
diff changeset
    75
:fail
14443efede32 Initial commit
Da Risk <da_risk@geekorum.com>
parents:
diff changeset
    76
rem Set variable GRADLE_EXIT_CONSOLE if you need the _script_ return code instead of
14443efede32 Initial commit
Da Risk <da_risk@geekorum.com>
parents:
diff changeset
    77
rem the _cmd.exe /c_ return code!
14443efede32 Initial commit
Da Risk <da_risk@geekorum.com>
parents:
diff changeset
    78
if  not "" == "%GRADLE_EXIT_CONSOLE%" exit 1
14443efede32 Initial commit
Da Risk <da_risk@geekorum.com>
parents:
diff changeset
    79
exit /b 1
14443efede32 Initial commit
Da Risk <da_risk@geekorum.com>
parents:
diff changeset
    80
14443efede32 Initial commit
Da Risk <da_risk@geekorum.com>
parents:
diff changeset
    81
:mainEnd
14443efede32 Initial commit
Da Risk <da_risk@geekorum.com>
parents:
diff changeset
    82
if "%OS%"=="Windows_NT" endlocal
14443efede32 Initial commit
Da Risk <da_risk@geekorum.com>
parents:
diff changeset
    83
14443efede32 Initial commit
Da Risk <da_risk@geekorum.com>
parents:
diff changeset
    84
:omega