Skip to content

Commit

Permalink
Got rid of duplication in gradle
Browse files Browse the repository at this point in the history
CR illu
  • Loading branch information
Zabuzard committed Feb 2, 2022
1 parent b91f9e6 commit ac1eb59
Showing 1 changed file with 3 additions and 12 deletions.
15 changes: 3 additions & 12 deletions build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -51,8 +51,7 @@ subprojects {
}
}


compileJava {
def compileTasks = {
options.encoding = 'UTF-8'

// Makes spotlessApply task run on every compile/build.
Expand All @@ -63,16 +62,8 @@ subprojects {
targetCompatibility = JavaVersion.VERSION_17
}

compileTestJava {
options.encoding = 'UTF-8'

// Makes spotlessApply task run on every compile/build.
dependsOn 'spotlessApply'

// Nails the Java-Version of every Subproject
sourceCompatibility = JavaVersion.VERSION_17
targetCompatibility = JavaVersion.VERSION_17
}
compileJava(compileTasks)
compileTestJava(compileTasks)

spotless {
java {
Expand Down

0 comments on commit ac1eb59

Please sign in to comment.