database/gradle/compile/java.gradle

33 lines
618 B
Groovy
Raw Normal View History

2022-02-10 18:41:26 +01:00
apply plugin: 'java-library'
java {
modularity.inferModulePath.set(true)
withSourcesJar()
withJavadocJar()
2022-02-10 18:41:26 +01:00
}
compileJava {
sourceCompatibility = JavaVersion.VERSION_17
targetCompatibility = JavaVersion.VERSION_17
2022-02-10 18:41:26 +01:00
}
compileTestJava {
sourceCompatibility = JavaVersion.VERSION_17
targetCompatibility = JavaVersion.VERSION_17
2022-02-10 18:41:26 +01:00
}
jar {
manifest {
attributes('Implementation-Version': project.version)
}
}
tasks.withType(JavaCompile) {
options.compilerArgs << '-Xlint:all,-fallthrough,-exports,-try'
2022-02-10 18:41:26 +01:00
}
javadoc {
options.addStringOption('Xdoclint:none', '-quiet')
}