aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--.gitignore32
-rw-r--r--.idea/codeStyles/Project.xml116
-rw-r--r--.idea/gradle.xml20
-rw-r--r--.idea/inspectionProfiles/Project_Default.xml15
-rw-r--r--.idea/runConfigurations.xml12
-rw-r--r--app/.gitignore1
-rw-r--r--app/build.gradle92
-rw-r--r--app/proguard-rules.pro21
-rw-r--r--app/src/androidTest/java/ml/docilealligator/infinityforreddit/ExampleInstrumentedTest.java26
-rw-r--r--app/src/test/java/ml/docilealligator/infinityforreddit/ExampleUnitTest.java17
-rw-r--r--build.gradle17
-rw-r--r--gradle/wrapper/gradle-wrapper.jarbin53636 -> 58694 bytes
-rw-r--r--gradle/wrapper/gradle-wrapper.properties3
-rwxr-xr-xgradlew109
-rw-r--r--gradlew.bat33
15 files changed, 142 insertions, 372 deletions
diff --git a/.gitignore b/.gitignore
index 0620fa94..7bc61541 100644
--- a/.gitignore
+++ b/.gitignore
@@ -22,9 +22,8 @@ out/
/app/release
# Gradle files
-.gradle
.gradle/
-/build
+build/
# Signing files
.signing/
@@ -39,10 +38,8 @@ proguard/
*.log
# Android Studio
-/*/build/
-/*/local.properties
+local.properties
/*/out
-/*/*/build
/*/*/production
captures/
.navigation/
@@ -65,27 +62,7 @@ obj/
/out/
# User-specific configurations
-.idea/caches/
-.idea/libraries/
-.idea/shelf/
-.idea/workspace.xml
-.idea/tasks.xml
-.idea/.name
-.idea/compiler.xml
-.idea/copyright/profiles_settings.xml
-.idea/encodings.xml
-.idea/misc.xml
-.idea/modules.xml
-.idea/scopes/scope_settings.xml
-.idea/dictionaries
-.idea/vcs.xml
-.idea/jsLibraryMappings.xml
-.idea/datasources.xml
-.idea/dataSources.ids
-.idea/sqlDataSources.xml
-.idea/dynamic.xml
-.idea/uiDesigner.xml
-.idea/assetWizardSettings.xml
+.idea/
# OS-specific files
.DS_Store
@@ -120,9 +97,6 @@ hs_err_pid*
# JIRA plugin
atlassian-ide-plugin.xml
-# Mongo Explorer plugin
-.idea/mongoSettings.xml
-
# Crashlytics plugin (for Android Studio and IntelliJ)
com_crashlytics_export_strings.xml
crashlytics.properties
diff --git a/.idea/codeStyles/Project.xml b/.idea/codeStyles/Project.xml
deleted file mode 100644
index 681f41ae..00000000
--- a/.idea/codeStyles/Project.xml
+++ /dev/null
@@ -1,116 +0,0 @@
-<component name="ProjectCodeStyleConfiguration">
- <code_scheme name="Project" version="173">
- <codeStyleSettings language="XML">
- <indentOptions>
- <option name="CONTINUATION_INDENT_SIZE" value="4" />
- </indentOptions>
- <arrangement>
- <rules>
- <section>
- <rule>
- <match>
- <AND>
- <NAME>xmlns:android</NAME>
- <XML_ATTRIBUTE />
- <XML_NAMESPACE>^$</XML_NAMESPACE>
- </AND>
- </match>
- </rule>
- </section>
- <section>
- <rule>
- <match>
- <AND>
- <NAME>xmlns:.*</NAME>
- <XML_ATTRIBUTE />
- <XML_NAMESPACE>^$</XML_NAMESPACE>
- </AND>
- </match>
- <order>BY_NAME</order>
- </rule>
- </section>
- <section>
- <rule>
- <match>
- <AND>
- <NAME>.*:id</NAME>
- <XML_ATTRIBUTE />
- <XML_NAMESPACE>http://schemas.android.com/apk/res/android</XML_NAMESPACE>
- </AND>
- </match>
- </rule>
- </section>
- <section>
- <rule>
- <match>
- <AND>
- <NAME>.*:name</NAME>
- <XML_ATTRIBUTE />
- <XML_NAMESPACE>http://schemas.android.com/apk/res/android</XML_NAMESPACE>
- </AND>
- </match>
- </rule>
- </section>
- <section>
- <rule>
- <match>
- <AND>
- <NAME>name</NAME>
- <XML_ATTRIBUTE />
- <XML_NAMESPACE>^$</XML_NAMESPACE>
- </AND>
- </match>
- </rule>
- </section>
- <section>
- <rule>
- <match>
- <AND>
- <NAME>style</NAME>
- <XML_ATTRIBUTE />
- <XML_NAMESPACE>^$</XML_NAMESPACE>
- </AND>
- </match>
- </rule>
- </section>
- <section>
- <rule>
- <match>
- <AND>
- <NAME>.*</NAME>
- <XML_ATTRIBUTE />
- <XML_NAMESPACE>^$</XML_NAMESPACE>
- </AND>
- </match>
- <order>BY_NAME</order>
- </rule>
- </section>
- <section>
- <rule>
- <match>
- <AND>
- <NAME>.*</NAME>
- <XML_ATTRIBUTE />
- <XML_NAMESPACE>http://schemas.android.com/apk/res/android</XML_NAMESPACE>
- </AND>
- </match>
- <order>ANDROID_ATTRIBUTE_ORDER</order>
- </rule>
- </section>
- <section>
- <rule>
- <match>
- <AND>
- <NAME>.*</NAME>
- <XML_ATTRIBUTE />
- <XML_NAMESPACE>.*</XML_NAMESPACE>
- </AND>
- </match>
- <order>BY_NAME</order>
- </rule>
- </section>
- </rules>
- </arrangement>
- </codeStyleSettings>
- </code_scheme>
-</component> \ No newline at end of file
diff --git a/.idea/gradle.xml b/.idea/gradle.xml
deleted file mode 100644
index 5cd135a0..00000000
--- a/.idea/gradle.xml
+++ /dev/null
@@ -1,20 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<project version="4">
- <component name="GradleMigrationSettings" migrationVersion="1" />
- <component name="GradleSettings">
- <option name="linkedExternalProjectsSettings">
- <GradleProjectSettings>
- <option name="testRunner" value="PLATFORM" />
- <option name="distributionType" value="DEFAULT_WRAPPED" />
- <option name="externalProjectPath" value="$PROJECT_DIR$" />
- <option name="modules">
- <set>
- <option value="$PROJECT_DIR$" />
- <option value="$PROJECT_DIR$/app" />
- </set>
- </option>
- <option name="resolveModulePerSourceSet" value="false" />
- </GradleProjectSettings>
- </option>
- </component>
-</project> \ No newline at end of file
diff --git a/.idea/inspectionProfiles/Project_Default.xml b/.idea/inspectionProfiles/Project_Default.xml
deleted file mode 100644
index 9223ff2c..00000000
--- a/.idea/inspectionProfiles/Project_Default.xml
+++ /dev/null
@@ -1,15 +0,0 @@
-<component name="InspectionProjectProfileManager">
- <profile version="1.0">
- <option name="myName" value="Project Default" />
- <inspection_tool class="FieldCanBeLocal" enabled="true" level="WARNING" enabled_by_default="true">
- <option name="EXCLUDE_ANNOS">
- <value>
- <list size="1">
- <item index="0" class="java.lang.String" itemvalue="androidx.room.ColumnInfo" />
- </list>
- </value>
- </option>
- <option name="IGNORE_FIELDS_USED_IN_MULTIPLE_METHODS" value="true" />
- </inspection_tool>
- </profile>
-</component> \ No newline at end of file
diff --git a/.idea/runConfigurations.xml b/.idea/runConfigurations.xml
deleted file mode 100644
index 7f68460d..00000000
--- a/.idea/runConfigurations.xml
+++ /dev/null
@@ -1,12 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<project version="4">
- <component name="RunConfigurationProducerService">
- <option name="ignoredProducers">
- <set>
- <option value="org.jetbrains.plugins.gradle.execution.test.runner.AllInPackageGradleConfigurationProducer" />
- <option value="org.jetbrains.plugins.gradle.execution.test.runner.TestClassGradleConfigurationProducer" />
- <option value="org.jetbrains.plugins.gradle.execution.test.runner.TestMethodGradleConfigurationProducer" />
- </set>
- </option>
- </component>
-</project> \ No newline at end of file
diff --git a/app/.gitignore b/app/.gitignore
deleted file mode 100644
index 796b96d1..00000000
--- a/app/.gitignore
+++ /dev/null
@@ -1 +0,0 @@
-/build
diff --git a/app/build.gradle b/app/build.gradle
index 4ac3eb46..3f99cdd2 100644
--- a/app/build.gradle
+++ b/app/build.gradle
@@ -17,75 +17,71 @@ android {
}
}
compileOptions {
- sourceCompatibility = '1.8'
- targetCompatibility = '1.8'
+ sourceCompatibility JavaVersion.VERSION_1_8
+ targetCompatibility JavaVersion.VERSION_1_8
}
}
-repositories {
- maven {
- url "http://dl.bintray.com/rilixtech/maven"
- }
- mavenCentral()
- google()
- jcenter()
-}
-
dependencies {
- implementation fileTree(include: ['*.jar'], dir: 'libs')
implementation 'androidx.appcompat:appcompat:1.1.0'
- implementation 'com.google.android.material:material:1.2.0-alpha05'
- implementation 'androidx.constraintlayout:constraintlayout:1.1.3'
- implementation 'androidx.legacy:legacy-support-v4:1.0.0'
- implementation 'androidx.legacy:legacy-support-v13:1.0.0'
- testImplementation 'junit:junit:4.12'
- androidTestImplementation 'androidx.test:runner:1.2.0'
- androidTestImplementation 'androidx.test.espresso:espresso-core:3.2.0'
- implementation 'com.google.android.exoplayer:exoplayer:2.10.4'
implementation 'androidx.browser:browser:1.2.0'
- implementation 'com.alexvasilkov:gesture-views:2.5.2'
implementation 'androidx.cardview:cardview:1.0.0'
+ implementation 'androidx.constraintlayout:constraintlayout:1.1.3'
+ // Lifecycle components
+ def lifecycleVersion = '2.2.0'
+ implementation "androidx.lifecycle:lifecycle-extensions:$lifecycleVersion"
+ annotationProcessor "androidx.lifecycle:lifecycle-common-java8:$lifecycleVersion"
+ implementation 'androidx.paging:paging-runtime:2.1.2'
+ implementation 'androidx.preference:preference:1.1.1'
+ // Room components
+ def roomVersion = '2.2.5'
+ implementation "androidx.room:room-runtime:$roomVersion"
+ annotationProcessor "androidx.room:room-compiler:$roomVersion"
+ implementation 'androidx.work:work-runtime:2.3.4'
+ implementation 'com.google.android.material:material:1.2.0-alpha05'
+
+ implementation 'com.google.android.exoplayer:exoplayer-core:2.10.4'
+ implementation 'com.google.android.exoplayer:exoplayer-hls:2.10.4'
+ implementation 'com.google.android.exoplayer:exoplayer-ui:2.10.4'
+ implementation 'com.alexvasilkov:gesture-views:2.6.0'
implementation 'com.github.bumptech.glide:glide:4.10.0'
- implementation 'com.github.pwittchen:swipe-rx2:0.3.0'
annotationProcessor 'com.github.bumptech.glide:compiler:4.10.0'
- // Room components
- implementation "androidx.room:room-runtime:$rootProject.roomVersion"
- annotationProcessor "androidx.room:room-compiler:$rootProject.roomVersion"
- // Lifecycle components
- implementation "androidx.lifecycle:lifecycle-extensions:$rootProject.archLifecycleVersion"
- annotationProcessor "androidx.lifecycle:lifecycle-common-java8:$rootProject.archLifecycleVersion"
+ implementation 'com.github.pwittchen:swipe-rx2:0.3.0'
implementation 'io.reactivex.rxjava2:rxandroid:2.1.1'
- implementation 'io.reactivex.rxjava2:rxjava:2.2.14'
- implementation 'com.squareup.retrofit2:retrofit:2.6.2'
- implementation 'com.squareup.retrofit2:converter-scalars:2.6.2'
- implementation 'jp.wasabeef:glide-transformations:4.0.0'
- implementation 'com.google.dagger:dagger:2.25.2'
- annotationProcessor 'com.google.dagger:dagger-compiler:2.25.2'
- implementation 'com.jakewharton:butterknife:10.2.0'
- annotationProcessor 'com.jakewharton:butterknife-compiler:10.2.0'
- implementation 'com.github.santalu:aspect-ratio-imageview:1.0.6'
- implementation 'androidx.paging:paging-runtime:2.1.2'
+ implementation 'io.reactivex.rxjava2:rxjava:2.2.19'
+ implementation 'com.squareup.retrofit2:retrofit:2.7.2'
+ implementation 'com.squareup.retrofit2:converter-scalars:2.7.2'
+ implementation 'jp.wasabeef:glide-transformations:4.1.0'
+ implementation 'com.google.dagger:dagger:2.27'
+ annotationProcessor 'com.google.dagger:dagger-compiler:2.27'
+ implementation 'com.jakewharton:butterknife:10.2.1'
+ annotationProcessor 'com.jakewharton:butterknife-compiler:10.2.1'
+ implementation 'com.github.santalu:aspect-ratio-imageview:1.0.9'
implementation 'com.lsjwzh:materialloadingprogressbar:0.5.8-RELEASE'
implementation 'io.noties.markwon:core:4.3.1'
implementation 'io.noties.markwon:linkify:4.3.1'
implementation 'io.noties.markwon:ext-strikethrough:4.3.1'
- implementation "io.noties.markwon:simple-ext:4.3.1"
- implementation "io.noties.markwon:recycler-table:4.3.1"
+ implementation 'io.noties.markwon:simple-ext:4.3.1'
+ implementation 'io.noties.markwon:recycler-table:4.3.1'
implementation 'pl.droidsonroids.gif:android-gif-drawable:1.2.19'
- implementation 'com.github.Ferfalk:SimpleSearchView:0.1.4'
- implementation 'org.greenrobot:eventbus:3.1.1'
- implementation 'com.libRG:customtextview:2.2'
+ implementation 'com.github.Ferfalk:SimpleSearchView:0.1.5'
+ implementation 'org.greenrobot:eventbus:3.2.0'
+ implementation 'com.libRG:customtextview:2.4'
implementation 'com.github.Deishelon:RoundedBottomSheet:1.0.1'
- implementation 'com.github.livefront:bridge:v1.2.0'
+ implementation 'com.github.livefront:bridge:v1.2.1'
implementation 'com.evernote:android-state:1.4.1'
annotationProcessor 'com.evernote:android-state-processor:1.4.1'
- implementation 'androidx.work:work-runtime:2.3.4'
- implementation 'androidx.preference:preference:1.1.0'
implementation 'com.nex3z:flow-layout:1.3.0'
implementation 'com.r0adkll:slidableactivity:2.1.0'
implementation 'com.atlassian.commonmark:commonmark:0.13.1'
implementation 'com.google.code.gson:gson:2.8.6'
implementation 'me.zhanghai.android.fastscroll:library:1.1.2'
- implementation "im.ene.toro3:toro:$rootProject.toroVersion"
- implementation "im.ene.toro3:toro-ext-exoplayer:$rootProject.toroVersion"
+
+ def toroVersion = '3.7.0.2010003'
+ implementation "im.ene.toro3:toro:$toroVersion"
+ implementation "im.ene.toro3:toro-ext-exoplayer:$toroVersion"
+
+ testImplementation 'junit:junit:4.13'
+ androidTestImplementation 'androidx.test:runner:1.2.0'
+ androidTestImplementation 'androidx.test.espresso:espresso-core:3.2.0'
}
diff --git a/app/proguard-rules.pro b/app/proguard-rules.pro
deleted file mode 100644
index f1b42451..00000000
--- a/app/proguard-rules.pro
+++ /dev/null
@@ -1,21 +0,0 @@
-# Add project specific ProGuard rules here.
-# You can control the set of applied configuration files using the
-# proguardFiles setting in build.gradle.
-#
-# For more details, see
-# http://developer.android.com/guide/developing/tools/proguard.html
-
-# If your project uses WebView with JS, uncomment the following
-# and specify the fully qualified class name to the JavaScript interface
-# class:
-#-keepclassmembers class fqcn.of.javascript.interface.for.webview {
-# public *;
-#}
-
-# Uncomment this to preserve the line number information for
-# debugging stack traces.
-#-keepattributes SourceFile,LineNumberTable
-
-# If you keep the line number information, uncomment this to
-# hide the original source file name.
-#-renamesourcefileattribute SourceFile
diff --git a/app/src/androidTest/java/ml/docilealligator/infinityforreddit/ExampleInstrumentedTest.java b/app/src/androidTest/java/ml/docilealligator/infinityforreddit/ExampleInstrumentedTest.java
deleted file mode 100644
index c2ab8ce0..00000000
--- a/app/src/androidTest/java/ml/docilealligator/infinityforreddit/ExampleInstrumentedTest.java
+++ /dev/null
@@ -1,26 +0,0 @@
-package ml.docilealligator.infinityforreddit;
-
-import android.content.Context;
-import androidx.test.InstrumentationRegistry;
-import androidx.test.runner.AndroidJUnit4;
-
-import org.junit.Test;
-import org.junit.runner.RunWith;
-
-import static org.junit.Assert.*;
-
-/**
- * Instrumented test, which will execute on an Android device.
- *
- * @see <a href="http://d.android.com/tools/testing">Testing documentation</a>
- */
-@RunWith(AndroidJUnit4.class)
-public class ExampleInstrumentedTest {
- @Test
- public void useAppContext() throws Exception {
- // Context of the app under test.
- Context appContext = InstrumentationRegistry.getTargetContext();
-
- assertEquals("ml.docilealligator.infinityforreddit", appContext.getPackageName());
- }
-}
diff --git a/app/src/test/java/ml/docilealligator/infinityforreddit/ExampleUnitTest.java b/app/src/test/java/ml/docilealligator/infinityforreddit/ExampleUnitTest.java
deleted file mode 100644
index fc950db2..00000000
--- a/app/src/test/java/ml/docilealligator/infinityforreddit/ExampleUnitTest.java
+++ /dev/null
@@ -1,17 +0,0 @@
-package ml.docilealligator.infinityforreddit;
-
-import org.junit.Test;
-
-import static org.junit.Assert.*;
-
-/**
- * Example local unit test, which will execute on the development machine (host).
- *
- * @see <a href="http://d.android.com/tools/testing">Testing documentation</a>
- */
-public class ExampleUnitTest {
- @Test
- public void addition_isCorrect() throws Exception {
- assertEquals(4, 2 + 2);
- }
-} \ No newline at end of file
diff --git a/build.gradle b/build.gradle
index c71c119b..b8837c77 100644
--- a/build.gradle
+++ b/build.gradle
@@ -1,14 +1,12 @@
// Top-level build file where you can add configuration options common to all sub-projects/modules.
buildscript {
-
repositories {
google()
jcenter()
}
dependencies {
- classpath 'com.android.tools.build:gradle:3.5.3'
-
+ classpath 'com.android.tools.build:gradle:3.6.3'
// NOTE: Do not place your application dependencies here; they belong
// in the individual module build.gradle files
@@ -19,9 +17,10 @@ allprojects {
repositories {
google()
jcenter()
- maven { url 'https://jitpack.io' }
- maven { url 'https://dl.bintray.com/sysdata/maven' }
- maven { url 'http://repo.pageturner-reader.org' }
+ maven { url "https://jitpack.io" }
+ maven { url "https://dl.bintray.com/sysdata/maven" }
+ maven { url "https://dl.bintray.com/rilixtech/maven/" }
+ maven { url "http://repo.pageturner-reader.org" }
mavenCentral()
}
}
@@ -29,9 +28,3 @@ allprojects {
task clean(type: Delete) {
delete rootProject.buildDir
}
-
-ext {
- roomVersion = '2.2.5'
- archLifecycleVersion = '2.2.0'
- toroVersion = '3.7.0.2010003'
-} \ No newline at end of file
diff --git a/gradle/wrapper/gradle-wrapper.jar b/gradle/wrapper/gradle-wrapper.jar
index 13372aef..490fda85 100644
--- a/gradle/wrapper/gradle-wrapper.jar
+++ b/gradle/wrapper/gradle-wrapper.jar
Binary files differ
diff --git a/gradle/wrapper/gradle-wrapper.properties b/gradle/wrapper/gradle-wrapper.properties
index 15381952..6623300b 100644
--- a/gradle/wrapper/gradle-wrapper.properties
+++ b/gradle/wrapper/gradle-wrapper.properties
@@ -1,6 +1,5 @@
-#Thu Aug 22 20:30:24 HKT 2019
distributionBase=GRADLE_USER_HOME
distributionPath=wrapper/dists
+distributionUrl=https\://services.gradle.org/distributions/gradle-6.3-all.zip
zipStoreBase=GRADLE_USER_HOME
zipStorePath=wrapper/dists
-distributionUrl=https://services.gradle.org/distributions/gradle-5.4.1-all.zip
diff --git a/gradlew b/gradlew
index 9d82f789..2fe81a7d 100755
--- a/gradlew
+++ b/gradlew
@@ -1,4 +1,20 @@
-#!/usr/bin/env bash
+#!/usr/bin/env sh
+
+#
+# Copyright 2015 the original author or authors.
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+# https://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+#
##############################################################################
##
@@ -6,20 +22,38 @@
##
##############################################################################
-# Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script.
-DEFAULT_JVM_OPTS=""
+# Attempt to set APP_HOME
+# Resolve links: $0 may be a link
+PRG="$0"
+# Need this for relative symlinks.
+while [ -h "$PRG" ] ; do
+ ls=`ls -ld "$PRG"`
+ link=`expr "$ls" : '.*-> \(.*\)$'`
+ if expr "$link" : '/.*' > /dev/null; then
+ PRG="$link"
+ else
+ PRG=`dirname "$PRG"`"/$link"
+ fi
+done
+SAVED="`pwd`"
+cd "`dirname \"$PRG\"`/" >/dev/null
+APP_HOME="`pwd -P`"
+cd "$SAVED" >/dev/null
APP_NAME="Gradle"
APP_BASE_NAME=`basename "$0"`
+# Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script.
+DEFAULT_JVM_OPTS='"-Xmx64m" "-Xms64m"'
+
# Use the maximum available, or set MAX_FD != -1 to use that value.
MAX_FD="maximum"
-warn ( ) {
+warn () {
echo "$*"
}
-die ( ) {
+die () {
echo
echo "$*"
echo
@@ -30,6 +64,7 @@ die ( ) {
cygwin=false
msys=false
darwin=false
+nonstop=false
case "`uname`" in
CYGWIN* )
cygwin=true
@@ -40,26 +75,11 @@ case "`uname`" in
MINGW* )
msys=true
;;
+ NONSTOP* )
+ nonstop=true
+ ;;
esac
-# Attempt to set APP_HOME
-# Resolve links: $0 may be a link
-PRG="$0"
-# Need this for relative symlinks.
-while [ -h "$PRG" ] ; do
- ls=`ls -ld "$PRG"`
- link=`expr "$ls" : '.*-> \(.*\)$'`
- if expr "$link" : '/.*' > /dev/null; then
- PRG="$link"
- else
- PRG=`dirname "$PRG"`"/$link"
- fi
-done
-SAVED="`pwd`"
-cd "`dirname \"$PRG\"`/" >/dev/null
-APP_HOME="`pwd -P`"
-cd "$SAVED" >/dev/null
-
CLASSPATH=$APP_HOME/gradle/wrapper/gradle-wrapper.jar
# Determine the Java command to use to start the JVM.
@@ -85,7 +105,7 @@ location of your Java installation."
fi
# Increase the maximum file descriptors if we can.
-if [ "$cygwin" = "false" -a "$darwin" = "false" ] ; then
+if [ "$cygwin" = "false" -a "$darwin" = "false" -a "$nonstop" = "false" ] ; then
MAX_FD_LIMIT=`ulimit -H -n`
if [ $? -eq 0 ] ; then
if [ "$MAX_FD" = "maximum" -o "$MAX_FD" = "max" ] ; then
@@ -105,8 +125,8 @@ if $darwin; then
GRADLE_OPTS="$GRADLE_OPTS \"-Xdock:name=$APP_NAME\" \"-Xdock:icon=$APP_HOME/media/gradle.icns\""
fi
-# For Cygwin, switch paths to Windows format before running java
-if $cygwin ; then
+# For Cygwin or MSYS, switch paths to Windows format before running java
+if [ "$cygwin" = "true" -o "$msys" = "true" ] ; then
APP_HOME=`cygpath --path --mixed "$APP_HOME"`
CLASSPATH=`cygpath --path --mixed "$CLASSPATH"`
JAVACMD=`cygpath --unix "$JAVACMD"`
@@ -134,27 +154,30 @@ if $cygwin ; then
else
eval `echo args$i`="\"$arg\""
fi
- i=$((i+1))
+ i=`expr $i + 1`
done
case $i in
- (0) set -- ;;
- (1) set -- "$args0" ;;
- (2) set -- "$args0" "$args1" ;;
- (3) set -- "$args0" "$args1" "$args2" ;;
- (4) set -- "$args0" "$args1" "$args2" "$args3" ;;
- (5) set -- "$args0" "$args1" "$args2" "$args3" "$args4" ;;
- (6) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" ;;
- (7) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" "$args6" ;;
- (8) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" "$args6" "$args7" ;;
- (9) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" "$args6" "$args7" "$args8" ;;
+ 0) set -- ;;
+ 1) set -- "$args0" ;;
+ 2) set -- "$args0" "$args1" ;;
+ 3) set -- "$args0" "$args1" "$args2" ;;
+ 4) set -- "$args0" "$args1" "$args2" "$args3" ;;
+ 5) set -- "$args0" "$args1" "$args2" "$args3" "$args4" ;;
+ 6) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" ;;
+ 7) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" "$args6" ;;
+ 8) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" "$args6" "$args7" ;;
+ 9) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" "$args6" "$args7" "$args8" ;;
esac
fi
-# Split up the JVM_OPTS And GRADLE_OPTS values into an array, following the shell quoting and substitution rules
-function splitJvmOpts() {
- JVM_OPTS=("$@")
+# Escape application args
+save () {
+ for i do printf %s\\n "$i" | sed "s/'/'\\\\''/g;1s/^/'/;\$s/\$/' \\\\/" ; done
+ echo " "
}
-eval splitJvmOpts $DEFAULT_JVM_OPTS $JAVA_OPTS $GRADLE_OPTS
-JVM_OPTS[${#JVM_OPTS[*]}]="-Dorg.gradle.appname=$APP_BASE_NAME"
+APP_ARGS=`save "$@"`
+
+# Collect all arguments for the java command, following the shell quoting and substitution rules
+eval set -- $DEFAULT_JVM_OPTS $JAVA_OPTS $GRADLE_OPTS "\"-Dorg.gradle.appname=$APP_BASE_NAME\"" -classpath "\"$CLASSPATH\"" org.gradle.wrapper.GradleWrapperMain "$APP_ARGS"
-exec "$JAVACMD" "${JVM_OPTS[@]}" -classpath "$CLASSPATH" org.gradle.wrapper.GradleWrapperMain "$@"
+exec "$JAVACMD" "$@"
diff --git a/gradlew.bat b/gradlew.bat
index aec99730..9109989e 100644
--- a/gradlew.bat
+++ b/gradlew.bat
@@ -1,3 +1,19 @@
+@rem
+@rem Copyright 2015 the original author or authors.
+@rem
+@rem Licensed under the Apache License, Version 2.0 (the "License");
+@rem you may not use this file except in compliance with the License.
+@rem You may obtain a copy of the License at
+@rem
+@rem https://www.apache.org/licenses/LICENSE-2.0
+@rem
+@rem Unless required by applicable law or agreed to in writing, software
+@rem distributed under the License is distributed on an "AS IS" BASIS,
+@rem WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+@rem See the License for the specific language governing permissions and
+@rem limitations under the License.
+@rem
+
@if "%DEBUG%" == "" @echo off
@rem ##########################################################################
@rem
@@ -8,14 +24,17 @@
@rem Set local scope for the variables with windows NT shell
if "%OS%"=="Windows_NT" setlocal
-@rem Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script.
-set DEFAULT_JVM_OPTS=
-
set DIRNAME=%~dp0
if "%DIRNAME%" == "" set DIRNAME=.
set APP_BASE_NAME=%~n0
set APP_HOME=%DIRNAME%
+@rem Resolve any "." and ".." in APP_HOME to make it shorter.
+for %%i in ("%APP_HOME%") do set APP_HOME=%%~fi
+
+@rem Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script.
+set DEFAULT_JVM_OPTS="-Xmx64m" "-Xms64m"
+
@rem Find java.exe
if defined JAVA_HOME goto findJavaFromJavaHome
@@ -46,10 +65,9 @@ echo location of your Java installation.
goto fail
:init
-@rem Get command-line arguments, handling Windowz variants
+@rem Get command-line arguments, handling Windows variants
if not "%OS%" == "Windows_NT" goto win9xME_args
-if "%@eval[2+2]" == "4" goto 4NT_args
:win9xME_args
@rem Slurp the command line arguments.
@@ -60,11 +78,6 @@ set _SKIP=2
if "x%~1" == "x" goto execute
set CMD_LINE_ARGS=%*
-goto execute
-
-:4NT_args
-@rem Get arguments from the 4NT Shell from JP Software
-set CMD_LINE_ARGS=%$
:execute
@rem Setup the command line