110 lines
2.8 KiB
Groovy
110 lines
2.8 KiB
Groovy
plugins {
|
|
alias(catalog.plugins.lombok) apply false
|
|
alias(catalog.plugins.wildfly)
|
|
id 'war'
|
|
id 'maven-publish'
|
|
}
|
|
|
|
import net.woggioni.gradle.wildfly.Deploy2WildflyTask
|
|
|
|
allprojects {
|
|
apply plugin: 'net.woggioni.gradle.lombok'
|
|
|
|
group = 'net.woggioni'
|
|
version = getProperty('jpacrepo.version')
|
|
|
|
repositories {
|
|
maven {
|
|
url = 'https://woggioni.net/mvn/'
|
|
content {
|
|
includeGroup 'net.woggioni'
|
|
includeGroup 'com.lys'
|
|
}
|
|
}
|
|
mavenCentral()
|
|
}
|
|
|
|
dependencies {
|
|
implementation platform(group: 'com.lys', name: 'lys-dependencies', version: getProperty('lys.version'))
|
|
}
|
|
|
|
lombok {
|
|
version = getProperty('lombok.version')
|
|
}
|
|
|
|
tasks.withType(JavaCompile) {
|
|
options.release = 17
|
|
}
|
|
|
|
tasks.withType(Test) {
|
|
useJUnitPlatform()
|
|
}
|
|
}
|
|
|
|
|
|
dependencies {
|
|
implementation project(':jpacrepo-impl')
|
|
|
|
implementation catalog.jwo
|
|
implementation catalog.slf4j.api
|
|
|
|
compileOnly catalog.hibernate.jpamodelgen
|
|
compileOnly catalog.jakarta.enterprise.cdi.api
|
|
compileOnly catalog.jakarta.servlet.api
|
|
compileOnly catalog.jakarta.ejb.api
|
|
compileOnly catalog.jakarta.ws.rs.api
|
|
compileOnly catalog.jakarta.xml.bind.api
|
|
compileOnly catalog.jakarta.enterprise.concurrent.api
|
|
|
|
|
|
implementation catalog.commons.compress
|
|
implementation catalog.jna
|
|
|
|
|
|
testImplementation catalog.jackson.module.jakarta.xmlbind.annotations
|
|
testImplementation catalog.jboss.ejb.client
|
|
testImplementation catalog.weld.se.core
|
|
testImplementation catalog.h2
|
|
testImplementation catalog.hibernate.core
|
|
testImplementation catalog.resteasy.client
|
|
testImplementation catalog.resteasy.jackson2.provider
|
|
testImplementation catalog.jackson.datatype.jsr310
|
|
testRuntimeOnly catalog.slf4j.simple
|
|
testImplementation catalog.junit.jupiter.api
|
|
testImplementation catalog.junit.jupiter.params
|
|
testRuntimeOnly catalog.junit.jupiter.engine
|
|
}
|
|
|
|
File nimDir = project.file('nim')
|
|
File srcDir = new File(nimDir, 'src')
|
|
File staticDir = new File(nimDir, 'static')
|
|
|
|
Provider<Exec> nimCompileTaskProvider = tasks.register("compileNim", Exec) {
|
|
inputs.files(project.fileTree(srcDir), project.fileTree(staticDir))
|
|
File outputFile = new File(temporaryDir, "jpacrepo.js")
|
|
outputs.file(outputFile)
|
|
commandLine 'nim', 'js', "-o:$outputFile", 'src/jpacrepo.nim'
|
|
workingDir(nimDir)
|
|
}
|
|
|
|
Provider<War> warTaskProvider = tasks.named('war', War) {
|
|
from staticDir
|
|
from nimCompileTaskProvider
|
|
}
|
|
|
|
tasks.named('deploy2Wildfly', Deploy2WildflyTask) {
|
|
}
|
|
|
|
publishing {
|
|
repositories {
|
|
maven {
|
|
url = 'https://mvn.woggioni.net/'
|
|
}
|
|
}
|
|
publications {
|
|
maven(MavenPublication) {
|
|
from(components["web"])
|
|
}
|
|
}
|
|
}
|