Skip to content

Commit

Permalink
Use Gradle's release property
Browse files Browse the repository at this point in the history
  • Loading branch information
marcphilipp committed Jun 20, 2021
1 parent caacd8d commit e25127d
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ val moduleSourceDir = file("src/module/java")

tasks {
compileJava {
options.compilerArgs = listOf("--release", "6")
options.release.set(6)
}

val compileModule by registering(JavaCompile::class) {
Expand All @@ -49,8 +49,8 @@ tasks {
classpath = files(compileJava.map { it.classpath })
inputs.property("moduleName", moduleName)
inputs.property("moduleVersion", project.version)
options.release.set(9)
options.compilerArgs = listOf(
"--release", "9",
"--module-version", project.version as String,
"--module-source-path", moduleSourceDir.toString(),
"--patch-module", "$moduleName=${sourceSets.main.get().allJava.srcDirs.joinToString(":")}",
Expand Down

0 comments on commit e25127d

Please sign in to comment.