build: Add Spotless Fail Fast to the build process (#7515)

* Add Spotless Fail Fast to the build process

---------

Signed-off-by: 7suyash7 <suyashnyn1@gmail.com>
Co-authored-by: Usman Saleem <usman@usmans.info>
pull/7530/head
Suyash Nayan 3 months ago committed by GitHub
parent e0aa4f6d4a
commit c656ece8fc
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
  1. 12
      build.gradle

@ -45,6 +45,10 @@ sonarqube {
}
}
tasks.register('spotlessCheckFast') {
dependsOn subprojects.collect { it.tasks.withType(com.diffplug.gradle.spotless.SpotlessCheck) }
}
project.tasks["sonarqube"].dependsOn "jacocoRootReport"
if (!JavaVersion.current().isCompatibleWith(JavaVersion.VERSION_21)) {
@ -432,6 +436,12 @@ allprojects {
options.addStringOption('Xwerror', '-html5')
options.encoding = 'UTF-8'
}
plugins.withType(JavaPlugin) {
tasks.withType(JavaCompile) {
it.dependsOn(rootProject.tasks.named('spotlessCheckFast'))
}
}
}
task deploy() {}
@ -455,7 +465,7 @@ task checkMavenCoordinateCollisions {
tasks.register('checkPluginAPIChanges', DefaultTask) {}
checkPluginAPIChanges.dependsOn(':plugin-api:checkAPIChanges')
check.dependsOn('checkPluginAPIChanges', 'checkMavenCoordinateCollisions')
check.dependsOn('checkPluginAPIChanges', 'checkMavenCoordinateCollisions', 'spotlessCheckFast')
subprojects {

Loading…
Cancel
Save