diff --git a/build.gradle b/build.gradle index d782a3089f..b988a4393a 100644 --- a/build.gradle +++ b/build.gradle @@ -17,6 +17,7 @@ buildscript { ext.jfrogExtractorVersion = "4.17.2" ext.bndVersion = "5.2.0" ext.checkstyleVersion = "8.26" + ext.googleJavaFromatterVersion = "0.9" // -------------------------------------- @@ -34,6 +35,7 @@ buildscript { classpath "com.jfrog.bintray.gradle:gradle-bintray-plugin:$bintrayVersion" classpath "org.jfrog.buildinfo:build-info-extractor-gradle:$jfrogExtractorVersion" classpath "biz.aQute.bnd:biz.aQute.bnd.gradle:$bndVersion" + classpath "gradle.plugin.com.github.sherter.google-java-format:google-java-format-gradle-plugin:$googleJavaFromatterVersion" } } @@ -65,6 +67,7 @@ apply plugin: "com.github.hierynomus.license" apply plugin: "com.jfrog.bintray" apply plugin: "com.jfrog.artifactory" apply plugin: "eclipse" +apply plugin: "com.github.sherter.google-java-format" sourceCompatibility = JavaVersion.VERSION_1_8 targetCompatibility = JavaVersion.VERSION_1_8 @@ -376,3 +379,8 @@ if (rootProject.hasProperty("releaseMode")) { } apply from: file("gradle/javadoc_cleanup.gradle") + +tasks.verifyGoogleJavaFormat.ignoreFailures = true +googleJavaFormat { + toolVersion = '1.1' +} \ No newline at end of file