96 lines
2.5 KiB
Groovy
96 lines
2.5 KiB
Groovy
plugins {
|
|
id 'java'
|
|
id 'org.springframework.boot' version '3.5.7'
|
|
id 'io.spring.dependency-management' version '1.1.7'
|
|
}
|
|
|
|
group = '__BASE_PACKAGE__'
|
|
version = '0.0.1-SNAPSHOT'
|
|
description = '__DESCRIPTION__'
|
|
|
|
java {
|
|
toolchain {
|
|
languageVersion = JavaLanguageVersion.of(17)
|
|
}
|
|
}
|
|
|
|
configurations {
|
|
compileOnly {
|
|
extendsFrom annotationProcessor
|
|
}
|
|
}
|
|
|
|
def giteaUser = findProperty('giteaUser')
|
|
?: System.getenv('GITEA_MAVEN_USER')
|
|
?: ''
|
|
def giteaToken = findProperty('giteaToken')
|
|
?: System.getenv('GITEA_MAVEN_TOKEN')
|
|
?: ''
|
|
|
|
repositories {
|
|
mavenCentral()
|
|
|
|
maven {
|
|
name = 'gitea'
|
|
url = uri('https://gitea.kric.com/api/packages/KRi/maven')
|
|
credentials {
|
|
username = giteaUser
|
|
password = giteaToken
|
|
}
|
|
}
|
|
}
|
|
|
|
configurations.configureEach {
|
|
resolutionStrategy.cacheDynamicVersionsFor 0, 'seconds'
|
|
}
|
|
|
|
dependencies {
|
|
implementation 'com.kri.common:starter:latest.release'
|
|
|
|
implementation 'org.springframework.boot:spring-boot-starter-web'
|
|
implementation 'org.springframework.boot:spring-boot-starter-security'
|
|
implementation 'org.springframework.boot:spring-boot-starter-validation'
|
|
implementation 'org.springframework.boot:spring-boot-starter-data-jpa'
|
|
implementation 'org.springframework.boot:spring-boot-starter-jdbc'
|
|
implementation 'org.springdoc:springdoc-openapi-starter-webmvc-ui:2.8.11'
|
|
|
|
implementation 'io.github.openfeign.querydsl:querydsl-jpa:7.1'
|
|
annotationProcessor 'com.querydsl:querydsl-apt:5.0.0:jakarta'
|
|
annotationProcessor 'jakarta.annotation:jakarta.annotation-api'
|
|
annotationProcessor 'jakarta.persistence:jakarta.persistence-api'
|
|
|
|
__DATABASE_DEPENDENCY__
|
|
__MYBATIS_DEPENDENCY__
|
|
|
|
compileOnly 'org.projectlombok:lombok'
|
|
annotationProcessor 'org.projectlombok:lombok'
|
|
|
|
developmentOnly 'org.springframework.boot:spring-boot-devtools'
|
|
|
|
testImplementation 'org.springframework.boot:spring-boot-starter-test'
|
|
testImplementation 'org.springframework.security:spring-security-test'
|
|
__MYBATIS_TEST_DEPENDENCY__
|
|
testRuntimeOnly 'org.junit.platform:junit-platform-launcher'
|
|
}
|
|
|
|
def querydslDir = layout.buildDirectory.dir('generated/querydsl').get().asFile
|
|
|
|
sourceSets {
|
|
main.java.srcDirs += [querydslDir]
|
|
}
|
|
|
|
tasks.withType(JavaCompile).configureEach {
|
|
options.encoding = 'UTF-8'
|
|
options.generatedSourceOutputDirectory.set(file(querydslDir))
|
|
}
|
|
|
|
tasks.named('test') {
|
|
useJUnitPlatform()
|
|
}
|
|
|
|
tasks.named('clean') {
|
|
doLast {
|
|
delete querydslDir
|
|
}
|
|
}
|