@@ -2,18 +2,19 @@ import common.properties
22import org.gradle.api.tasks.testing.logging.TestExceptionFormat
33import org.gradle.api.tasks.testing.logging.TestLogEvent
44
5- plugins{
5+ plugins {
66 `java`
77 `jvm- test- suite`
88 id(" com.dorongold.task-tree" )
99 id(" com.glovoapp.semantic-versioning" )
1010}
1111
12- semanticVersion{
12+ semanticVersion {
1313 // if the propertiesFile is not changed the plugin will look for a file in each module.
1414 propertiesFile.set(project.rootProject.file(" version.properties" ))
1515}
16- tasks.incrementSemanticVersion{
16+
17+ tasks.incrementSemanticVersion {
1718 // disable the task for all projects.
1819 // because digma-base is applied to all projects then calling incrementSemanticVersion will be invoked
1920 // for each project and we don't want that.
@@ -24,12 +25,11 @@ tasks.incrementSemanticVersion{
2425
2526java {
2627 toolchain {
27- languageVersion.set(JavaLanguageVersion .of(properties(" javaVersion" ,project)))
28- vendor.set(JvmVendorSpec .AMAZON )
28+ languageVersion.set(JavaLanguageVersion .of(properties(" javaVersion" , project)))
2929 }
3030}
3131
32- group = properties(" pluginGroup" ,project)
32+ group = properties(" pluginGroup" , project)
3333version = project.semanticVersion.version.get()
3434
3535repositories {
@@ -46,12 +46,12 @@ configurations {
4646}
4747
4848
49- project.afterEvaluate{
50- tasks{
49+ project.afterEvaluate {
50+ tasks {
5151 // the project can be built with build task or buildPlugin task. build triggers buildPlugin.
5252 // but buildPlugin doesn't trigger build, so if calling only buildPlugin unit tests will not run.
5353 // if the project is built by calling buildPlugin we want it to trigger test.
54- named(" buildPlugin" ){
54+ named(" buildPlugin" ) {
5555 dependsOn(test)
5656 }
5757 }
@@ -93,9 +93,7 @@ testing {
9393
9494
9595
96-
97-
98- tasks{
96+ tasks {
9997
10098 withType<JavaCompile > {
10199 options.compilerArgs.addAll(listOf (" -Xlint:unchecked,deprecation" ))
@@ -131,7 +129,6 @@ tasks{
131129 }
132130 })
133131
134-
135132 testLogging {
136133 lifecycle {
137134 events = mutableSetOf (TestLogEvent .FAILED )
@@ -162,6 +159,4 @@ tasks{
162159 }
163160 }
164161
165-
166-
167162}
0 commit comments