From 6c58c30b67fe2122e8eed975741647fec617b1b9 Mon Sep 17 00:00:00 2001 From: Mygod Date: Thu, 20 Jun 2019 09:36:40 +0800 Subject: [PATCH] Update dependencies --- .circleci/config.yml | 2 +- app/build.gradle | 20 +++++-------------- app/src/main/AndroidManifest.xml | 2 ++ app/src/main/go/v2ray-plugin | 2 +- .../plugin/v2ray/ConfigFragment.kt | 12 +++++------ build.gradle | 6 +++--- gradle.properties | 1 - gradle/wrapper/gradle-wrapper.properties | 2 +- 8 files changed, 19 insertions(+), 28 deletions(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index 714e09c..64bd600 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -3,7 +3,7 @@ jobs: build: working_directory: ~/code docker: - - image: shadowsocks/shadowsocks-android:circleci + - image: shadowsocks/android-ndk-go environment: JVM_OPTS: -Xmx3500m GRADLE_OPTS: -Dorg.gradle.workers.max=1 -Dorg.gradle.daemon=false -Dkotlin.compiler.execution.strategy="in-process" diff --git a/app/build.gradle b/app/build.gradle index 19d89bf..24cd046 100644 --- a/app/build.gradle +++ b/app/build.gradle @@ -18,7 +18,6 @@ def getCurrentFlavor() { } android { - buildToolsVersion "28.0.3" compileSdkVersion 28 defaultConfig { applicationId "com.github.shadowsocks.plugin.v2ray" @@ -55,15 +54,6 @@ task goBuild(type: Exec) { } } -task goClean(type: Exec) { - if (Os.isFamily(Os.FAMILY_WINDOWS)) { - println "Warning: Building on Windows is not supported" - } else { - executable "sh" - args "-c", "src/clean.bash" - } -} - tasks.whenTaskAdded { task -> if ((task.name == 'javaPreCompileDebug' || task.name == 'javaPreCompileRelease')) { @@ -73,13 +63,13 @@ tasks.whenTaskAdded { task -> dependencies { implementation fileTree(dir: 'libs', include: ['*.jar']) - implementation "androidx.preference:preference:1.1.0-alpha03" - implementation 'com.github.shadowsocks:plugin:1.1.0' + implementation "androidx.preference:preference:1.1.0-beta01" + implementation 'com.github.shadowsocks:plugin:1.2.0' implementation 'com.takisoft.preferencex:preferencex-simplemenu:1.0.0' - implementation "org.jetbrains.kotlin:kotlin-stdlib-jdk7:$kotlinVersion" + implementation "org.jetbrains.kotlin:kotlin-stdlib-jdk8:$kotlinVersion" testImplementation 'junit:junit:4.12' - androidTestImplementation 'androidx.test:runner:1.1.1' - androidTestImplementation 'androidx.test.espresso:espresso-core:3.1.1' + androidTestImplementation 'androidx.test:runner:1.2.0' + androidTestImplementation 'androidx.test.espresso:espresso-core:3.2.0' } ext.abiCodes = ['armeabi-v7a': 1, 'arm64-v8a': 2, x86: 3, x86_64: 4] diff --git a/app/src/main/AndroidManifest.xml b/app/src/main/AndroidManifest.xml index 7c75d70..4a79bc6 100644 --- a/app/src/main/AndroidManifest.xml +++ b/app/src/main/AndroidManifest.xml @@ -22,6 +22,8 @@ + diff --git a/app/src/main/go/v2ray-plugin b/app/src/main/go/v2ray-plugin index d3c1201..e5ada30 160000 --- a/app/src/main/go/v2ray-plugin +++ b/app/src/main/go/v2ray-plugin @@ -1 +1 @@ -Subproject commit d3c12013b948ed7177cb1cde41e23d50256e3ae4 +Subproject commit e5ada302d39b0aef8e167701c94596e41e805ec1 diff --git a/app/src/main/java/com/github/shadowsocks/plugin/v2ray/ConfigFragment.kt b/app/src/main/java/com/github/shadowsocks/plugin/v2ray/ConfigFragment.kt index e3a7d02..a921081 100644 --- a/app/src/main/java/com/github/shadowsocks/plugin/v2ray/ConfigFragment.kt +++ b/app/src/main/java/com/github/shadowsocks/plugin/v2ray/ConfigFragment.kt @@ -39,12 +39,12 @@ class ConfigFragment : PreferenceFragmentCompat(), Preference.OnPreferenceChange const val REQUEST_BROWSE_CERTIFICATE = 1 } - private val mode by lazy { findPreference("mode") } - private val host by lazy { findPreference("host") } - private val path by lazy { findPreference("path") } - private val mux by lazy { findPreference("mux") } - private val certRaw by lazy { findPreference("certRaw") } - private val loglevel by lazy { findPreference("loglevel") } + private val mode by lazy { findPreference("mode")!! } + private val host by lazy { findPreference("host")!! } + private val path by lazy { findPreference("path")!! } + private val mux by lazy { findPreference("mux")!! } + private val certRaw by lazy { findPreference("certRaw")!! } + private val loglevel by lazy { findPreference("loglevel")!! } private fun readMode(value: String = mode.value) = when (value) { "websocket-http" -> Pair(null, false) diff --git a/build.gradle b/build.gradle index 84f7511..c76c0ad 100644 --- a/build.gradle +++ b/build.gradle @@ -4,7 +4,7 @@ apply plugin: 'com.github.ben-manes.versions' buildscript { ext { - kotlinVersion = '1.3.21' + kotlinVersion = '1.3.31' minSdkVersion = 21 } repositories { @@ -12,8 +12,8 @@ buildscript { jcenter() } dependencies { - classpath 'com.android.tools.build:gradle:3.3.1' - classpath 'com.github.ben-manes:gradle-versions-plugin:0.20.0' + classpath 'com.android.tools.build:gradle:3.5.0-beta04' + classpath 'com.github.ben-manes:gradle-versions-plugin:0.21.0' classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlinVersion" } } diff --git a/gradle.properties b/gradle.properties index 0c83f54..23c9085 100644 --- a/gradle.properties +++ b/gradle.properties @@ -7,7 +7,6 @@ # Specifies the JVM arguments used for the daemon process. # The setting is particularly useful for tweaking memory settings. android.enableJetifier=true -android.enableR8=true android.enableR8.fullMode=true android.useAndroidX=true org.gradle.jvmargs=-Xmx1536m diff --git a/gradle/wrapper/gradle-wrapper.properties b/gradle/wrapper/gradle-wrapper.properties index a5e6c5b..cc1bb20 100644 --- a/gradle/wrapper/gradle-wrapper.properties +++ b/gradle/wrapper/gradle-wrapper.properties @@ -3,4 +3,4 @@ distributionBase=GRADLE_USER_HOME distributionPath=wrapper/dists zipStoreBase=GRADLE_USER_HOME zipStorePath=wrapper/dists -distributionUrl=https\://services.gradle.org/distributions/gradle-5.2.1-all.zip +distributionUrl=https\://services.gradle.org/distributions/gradle-5.4.1-all.zip