disable lint in release builds + minor code style update
This commit is contained in:
parent
84e6a779ed
commit
760ec1e517
|
@ -36,6 +36,11 @@ android {
|
|||
debug.java.srcDirs += 'src/debug/kotlin'
|
||||
release.java.srcDirs += 'src/release/kotlin'
|
||||
}
|
||||
|
||||
lintOptions {
|
||||
checkReleaseBuilds false
|
||||
abortOnError false
|
||||
}
|
||||
}
|
||||
|
||||
ext {
|
||||
|
@ -50,6 +55,7 @@ dependencies {
|
|||
compile 'com.android.support:multidex:1.0.1'
|
||||
compile 'com.google.code.gson:gson:2.8.0'
|
||||
compile "org.jetbrains.kotlin:kotlin-stdlib:$kotlin_version"
|
||||
|
||||
debugCompile "com.squareup.leakcanary:leakcanary-android:$leakCanaryVersion"
|
||||
releaseCompile "com.squareup.leakcanary:leakcanary-android-no-op:$leakCanaryVersion"
|
||||
}
|
||||
|
|
|
@ -5,10 +5,8 @@ import com.squareup.leakcanary.LeakCanary
|
|||
open class BuildVariantApplication : BaseApp() {
|
||||
override fun onCreate() {
|
||||
super.onCreate()
|
||||
LeakCanary.install(this);
|
||||
LeakCanary.install(this)
|
||||
}
|
||||
|
||||
override fun shouldInit(): Boolean {
|
||||
return !LeakCanary.isInAnalyzerProcess(this)
|
||||
}
|
||||
override fun shouldInit() = !LeakCanary.isInAnalyzerProcess(this)
|
||||
}
|
||||
|
|
|
@ -3,7 +3,5 @@ package com.simplemobiletools.calendar
|
|||
import android.support.multidex.MultiDexApplication
|
||||
|
||||
abstract class BaseApp : MultiDexApplication() {
|
||||
open fun shouldInit(): Boolean {
|
||||
return true
|
||||
}
|
||||
open fun shouldInit() = true
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue