Rietveld Code Review Tool
Help | Bug tracker | Discussion group | Source code

Unified Diff: libadblockplus-android-settings/build.gradle

Issue 29347926: Issue 4248 - Add codestyle check
Patch Set: added Gradle support, removed Ant support, added original files URLs Created April 14, 2017, 11:56 a.m.
Use n/p to move between diff chunks; N/P to move between comments.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: libadblockplus-android-settings/build.gradle
diff --git a/libadblockplus-android-settings/build.gradle b/libadblockplus-android-settings/build.gradle
index 6a50134b7335a3cdcf8923fb43825d92d3ab979e..1e1d73678b1ce49b0488b3c77ce55028ebbe0dbe 100644
--- a/libadblockplus-android-settings/build.gradle
+++ b/libadblockplus-android-settings/build.gradle
@@ -1,4 +1,5 @@
apply plugin: 'com.android.library'
+apply plugin: 'checkstyle'
android {
compileSdkVersion 21
@@ -28,9 +29,28 @@ android {
}
}
-
-
dependencies {
compile project(':libadblockplus-android')
compile 'com.android.support:support-v4:21.0.3'
+}
+
+checkstyle {
+ toolVersion = '6.19'
+}
+
+task checkstyleMain(type: Checkstyle) {
+ ignoreFailures = true
+ showViolations = true
+ source 'src/org/adblockplus/'
+ exclude '**/gen/**'
+ exclude '**/R.java'
+ exclude '**/BuildConfig.java'
+ reports {
+ xml.destination "$project.buildDir/reports/checkstyle/main.xml"
+ }
+ classpath = files()
+ configFile = file("${rootProject.rootDir}/third_party/checkstyle/java/rules/eyeo_checks.xml")
diegocarloslima 2017/04/27 12:58:44 Are we using the other checks files? It seems that
anton 2017/04/28 06:05:06 yes, here we use 'eyeo_checks' only. but since it'
+ configProperties = [
+ "checkstyle.header.file" : file("${rootProject.rootDir}/third_party/checkstyle/java/res/header.txt")
+ ]
}

Powered by Google App Engine
This is Rietveld