Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Plugin 1.3.2 #2398

Merged
merged 5 commits into from Jan 11, 2020
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
2 changes: 1 addition & 1 deletion build.gradle
Expand Up @@ -10,7 +10,7 @@ buildscript {
sdkVersion = 29
compileSdkVersion = 29
lifecycleVersion = '2.2.0-rc03'
junitVersion = '4.12'
junitVersion = '4.13'
androidTestVersion = '1.2.0'
androidEspressoVersion = '3.2.0'
versionCode = 4080750
Expand Down
4 changes: 2 additions & 2 deletions core/build.gradle
Expand Up @@ -49,7 +49,7 @@ androidExtensions {
}

def coroutinesVersion = '1.3.3'
def roomVersion = '2.2.2'
def roomVersion = '2.2.3'
def workVersion = '2.2.0'
dependencies {
api project(':plugin')
Expand All @@ -64,7 +64,7 @@ dependencies {
api 'com.crashlytics.sdk.android:crashlytics:2.10.1'
api 'com.google.code.gson:gson:2.8.6'
api 'com.google.firebase:firebase-analytics:17.2.1'
api 'com.google.firebase:firebase-config:19.0.4'
api 'com.google.firebase:firebase-config:19.1.0'
api 'dnsjava:dnsjava:2.1.9'
api "org.jetbrains.kotlinx:kotlinx-coroutines-android:$coroutinesVersion"
api "org.jetbrains.kotlinx:kotlinx-coroutines-play-services:$coroutinesVersion"
Expand Down
21 changes: 18 additions & 3 deletions detekt.yml
@@ -1,4 +1,4 @@
# https://github.com/arturbosch/detekt/blob/1.1.1/detekt-cli/src/main/resources/default-detekt-config.yml
# https://github.com/arturbosch/detekt/blob/1.3.1/detekt-cli/src/main/resources/default-detekt-config.yml

comments:
active: false
Expand All @@ -14,9 +14,11 @@ complexity:
includeStaticDeclarations: false
ComplexMethod:
active: true
threshold: 10
threshold: 15
ignoreSingleWhenExpression: false
ignoreSimpleWhenEntries: false
ignoreNestingFunctions: false
nestingFunctions: run,let,apply,with,also,use,forEach,isNotNull,ifNull
LabeledExpression:
active: false
ignoredLabels: ""
Expand Down Expand Up @@ -245,6 +247,7 @@ naming:
parameterPattern: '[a-z][A-Za-z0-9]*'
privateParameterPattern: '[a-z][A-Za-z0-9]*'
excludeClassPattern: '$^'
ignoreOverridden: true
EnumNaming:
active: true
excludes: "**/test/**,**/androidTest/**,**/*.Test.kt,**/*.Spec.kt,**/*.Spek.kt"
Expand Down Expand Up @@ -337,6 +340,8 @@ potential-bugs:
active: true
HasPlatformType:
active: true
ImplicitDefaultLocale:
active: true
InvalidRange:
active: true
IteratorHasNextCallsNextMethod:
Expand All @@ -345,6 +350,8 @@ potential-bugs:
active: true
LateinitUsage:
active: false
MapGetWithNotNullAssertionOperator:
active: true
MissingWhenCase:
active: false
RedundantElseInWhen:
Expand All @@ -354,7 +361,7 @@ potential-bugs:
UnreachableCode:
active: true
UnsafeCallOnNullableType:
active: false
active: true
UnsafeCast:
active: false
UselessPostfixExpression:
Expand Down Expand Up @@ -387,6 +394,12 @@ style:
active: true
imports: ''
forbiddenPatterns: ""
ForbiddenMethodCall:
active: true
methods: ''
ForbiddenPublicDataClass:
active: true
ignorePackages: '*.internal,*.internal.*'
ForbiddenVoid:
active: true
ignoreOverridden: true
Expand Down Expand Up @@ -453,6 +466,8 @@ style:
UnnecessaryAbstractClass:
active: true
excludeAnnotatedClasses: "dagger.Module"
UnnecessaryAnnotationUseSiteTarget:
active: true
UnnecessaryApply:
active: true
UnnecessaryInheritance:
Expand Down
4 changes: 2 additions & 2 deletions mobile/build.gradle
Expand Up @@ -60,8 +60,8 @@ androidExtensions {

dependencies {
implementation project(':core')
implementation 'androidx.browser:browser:1.2.0-rc01'
implementation 'androidx.constraintlayout:constraintlayout:2.0.0-beta3'
implementation 'androidx.browser:browser:1.2.0'
implementation 'androidx.constraintlayout:constraintlayout:2.0.0-beta4'
implementation "androidx.lifecycle:lifecycle-runtime-ktx:$lifecycleVersion"
implementation 'com.google.android.gms:play-services-vision:19.0.0'
implementation 'com.google.firebase:firebase-ads:18.3.0'
Expand Down
6 changes: 6 additions & 0 deletions plugin/CHANGES.md
@@ -1,3 +1,9 @@
* 1.3.2:
* Fix first key-value pair disappearing with null value. (#2391)
* Dependency updates:
- `androidx.core:core-ktx:1.1.0`;
- `com.google.android.material:material:1.1.0-rc01`;
- `org.jetbrains.kotlin:kotlin-stdlib-jdk8:1.3.61`.
* 1.3.1:
* New theme resource `Theme.Shadowsocks.Immersive` for better Android Q-esque translucent navigation bars.
This is an opt-in feature.
Expand Down
2 changes: 1 addition & 1 deletion plugin/build.gradle
Expand Up @@ -57,7 +57,7 @@ mavenPublish {
dependencies {
api 'androidx.core:core-ktx:1.1.0'
api 'androidx.drawerlayout:drawerlayout:1.1.0-alpha03' // https://android-developers.googleblog.com/2019/07/android-q-beta-5-update.html
api 'com.google.android.material:material:1.1.0-beta02'
api 'com.google.android.material:material:1.1.0-rc01'
api "org.jetbrains.kotlin:kotlin-stdlib-jdk8:$kotlinVersion"
testImplementation "junit:junit:$junitVersion"
androidTestImplementation "androidx.test:runner:$androidTestVersion"
Expand Down
4 changes: 2 additions & 2 deletions plugin/gradle.properties
@@ -1,6 +1,6 @@
GROUP=com.github.shadowsocks
VERSION_NAME=1.3.1
VERSION_CODE=11
VERSION_NAME=1.3.2
VERSION_CODE=12

POM_ARTIFACT_ID=plugin
POM_NAME=Shadowsocks Plugin
Expand Down
2 changes: 1 addition & 1 deletion plugin/src/main/AndroidManifest.xml
Expand Up @@ -3,6 +3,6 @@
<application
android:theme="@style/Theme.Shadowsocks">
<meta-data android:name="com.github.shadowsocks.plugin.version"
android:value="1.3.1"/>
android:value="1.3.2"/>
</application>
</manifest>
Expand Up @@ -30,7 +30,7 @@ import androidx.appcompat.app.AppCompatActivity
*/
abstract class OptionsCapableActivity : AppCompatActivity() {
protected fun pluginOptions(intent: Intent = this.intent) = try {
PluginOptions(intent.getStringExtra(PluginContract.EXTRA_OPTIONS))
PluginOptions("", intent.getStringExtra(PluginContract.EXTRA_OPTIONS))
} catch (exc: IllegalArgumentException) {
Toast.makeText(this, exc.message, Toast.LENGTH_SHORT).show()
PluginOptions()
Expand Down
Expand Up @@ -36,6 +36,12 @@ class PluginOptionsTest {
Assert.assertEquals(true, o3 == o4)
}

@Test
fun nullValues() {
val o = PluginOptions("", "a;b;c;d=3")
Assert.assertEquals(true, o == PluginOptions("", o.toString()))
}

@Test
fun escape() {
val options = PluginOptions("escapeTest")
Expand Down
2 changes: 1 addition & 1 deletion tv/build.gradle
Expand Up @@ -56,7 +56,7 @@ android {
dependencies {
implementation project(':core')
implementation fileTree(dir: 'libs', include: ['*.jar'])
implementation "androidx.leanback:leanback-preference:1.1.0-alpha02"
implementation 'androidx.leanback:leanback-preference:1.1.0-alpha03'
}

apply plugin: 'com.google.gms.google-services'
Expand Down