gradle-plugins/gradle/compile/groovy.gradle

30 lines
660 B
Groovy
Raw Normal View History

2021-11-09 14:08:25 +01:00
apply plugin: 'groovy'
dependencies {
implementation libs.groovy.core
2021-11-09 14:08:25 +01:00
}
compileGroovy {
2023-05-21 13:16:00 +02:00
sourceCompatibility = JavaVersion.VERSION_17
targetCompatibility = JavaVersion.VERSION_17
2021-11-09 14:08:25 +01:00
}
compileTestGroovy {
2023-05-21 13:16:00 +02:00
sourceCompatibility = JavaVersion.VERSION_17
targetCompatibility = JavaVersion.VERSION_17
2021-11-09 14:08:25 +01:00
}
tasks.withType(GroovyCompile) {
options.compilerArgs
if (!options.compilerArgs.contains("-processor")) {
options.compilerArgs.add('-proc:none')
2021-11-09 14:08:25 +01:00
}
}
task groovydocJar(type: Jar) {
dependsOn groovydoc
2021-11-09 14:08:25 +01:00
from groovydoc.destinationDir
archiveClassifier.set('groovydoc')
}
tasks.assemble.dependsOn(tasks.groovydocJar)