set CLASSPATH=%APP_HOME%\gradle\wrapper\gradle-wrapper.jar
.
.
.
@rem Add default JVM options by parsing command line. Anything starting with -D is option to java.
:SYSTEM_PROPS_EXTRACT
set _OPTION=%1
set prefix1=%_OPTION:~0,2%
if "%prefix1%" == "-D" (
SET DEFAULT_JVM_OPTS=%DEFAULT_JVM_OPTS% %_OPTION%=%2%
)
shift
if not "%~1"=="" goto SYSTEM_PROPS_EXTRACT
echo Default JVM Options: %DEFAULT_JVM_OPTS%
.
.
.
.
@rem Execute Gradle
"%JAVA_EXE%" %DEFAULT_JVM_OPTS% %JAVA_OPTS% %GRADLE_OPTS%
"-Dorg.gradle.appname=%APP_BASE_NAME%"
-classpath "%CLASSPATH%" org.gradle.wrapper.GradleWrapperMain %CMD_LINE_ARGS%
Shell Script changes
.
.
.
.
#Add default JVM options by parsing command line arguments.
#Anything starting with -D is passed to JVM also.
for var in "$@"
do
prefix=${var:0:2}
if [[ $prefix == "-D" ]] ; then
DEFAULT_JVM_OPTS=$DEFAULT_JVM_OPTS" "$var
fi
done
# Split up the JVM_OPTS And GRADLE_OPTS values into an array,
# following the shell quoting and substitution rules
function splitJvmOpts() {
JVM_OPTS=("$@")
}
eval splitJvmOpts $DEFAULT_JVM_OPTS $JAVA_OPTS $GRADLE_OPTS
JVM_OPTS[${#JVM_OPTS[*]}]="-Dorg.gradle.appname=$APP_BASE_NAME"
echo "JVM_OPTS :""${JVM_OPTS[@]}"
.
.
.
exec "$JAVACMD" "${JVM_OPTS[@]}"
-classpath "$CLASSPATH" org.gradle.wrapper.GradleWrapperMain "$@"
And finally the proxy option to use gradlew build -Dhttp.proxyHost=www-xxx.com -Dhttp.proxyPort=80 -Dhttp.proxyUser=user1 -Dhttp.proxyPassword=user1 -Dhttp.auth.ntlm.domain=COMMON
No comments:
Post a Comment