Merge pull request #3828 from wb9688/checkstyle-fix
Do not include Checkstyle in any APK
This commit is contained in:
commit
c2b4a44a59
|
@ -91,6 +91,11 @@ ext {
|
||||||
markwonVersion = '4.3.1'
|
markwonVersion = '4.3.1'
|
||||||
}
|
}
|
||||||
|
|
||||||
|
configurations {
|
||||||
|
checkstyle
|
||||||
|
ktlint
|
||||||
|
}
|
||||||
|
|
||||||
checkstyle {
|
checkstyle {
|
||||||
configFile rootProject.file('checkstyle.xml')
|
configFile rootProject.file('checkstyle.xml')
|
||||||
ignoreFailures false
|
ignoreFailures false
|
||||||
|
@ -106,8 +111,7 @@ task runCheckstyle(type: Checkstyle) {
|
||||||
exclude '**/BuildConfig.java'
|
exclude '**/BuildConfig.java'
|
||||||
exclude 'main/java/us/shandian/giga/**'
|
exclude 'main/java/us/shandian/giga/**'
|
||||||
|
|
||||||
// empty classpath
|
classpath = configurations.checkstyle
|
||||||
classpath = files()
|
|
||||||
|
|
||||||
showViolations true
|
showViolations true
|
||||||
|
|
||||||
|
@ -117,10 +121,6 @@ task runCheckstyle(type: Checkstyle) {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
configurations {
|
|
||||||
ktlint
|
|
||||||
}
|
|
||||||
|
|
||||||
task runKtlint(type: JavaExec) {
|
task runKtlint(type: JavaExec) {
|
||||||
main = "com.pinterest.ktlint.Main"
|
main = "com.pinterest.ktlint.Main"
|
||||||
classpath = configurations.ktlint
|
classpath = configurations.ktlint
|
||||||
|
@ -143,7 +143,7 @@ dependencies {
|
||||||
implementation "frankiesardo:icepick:${icepickVersion}"
|
implementation "frankiesardo:icepick:${icepickVersion}"
|
||||||
kapt "frankiesardo:icepick-processor:${icepickVersion}"
|
kapt "frankiesardo:icepick-processor:${icepickVersion}"
|
||||||
|
|
||||||
debugImplementation "com.puppycrawl.tools:checkstyle:${checkstyleVersion}"
|
checkstyle "com.puppycrawl.tools:checkstyle:${checkstyleVersion}"
|
||||||
ktlint "com.pinterest:ktlint:0.35.0"
|
ktlint "com.pinterest:ktlint:0.35.0"
|
||||||
|
|
||||||
debugImplementation "com.facebook.stetho:stetho:${stethoVersion}"
|
debugImplementation "com.facebook.stetho:stetho:${stethoVersion}"
|
||||||
|
|
Loading…
Reference in New Issue