[QueryDSL 세팅 및 전체 구조 세팅]
This commit is contained in:
30
build.gradle
30
build.gradle
@@ -23,6 +23,12 @@ repositories {
|
||||
mavenCentral()
|
||||
}
|
||||
|
||||
buildscript {
|
||||
ext {
|
||||
queryDslVersion = "5.0.0"
|
||||
}
|
||||
}
|
||||
|
||||
dependencies {
|
||||
// 개발용 의존성 추가
|
||||
developmentOnly 'org.springframework.boot:spring-boot-devtools'
|
||||
@@ -34,9 +40,31 @@ dependencies {
|
||||
annotationProcessor 'org.projectlombok:lombok'
|
||||
testImplementation 'org.springframework.boot:spring-boot-starter-test'
|
||||
testRuntimeOnly 'org.junit.platform:junit-platform-launcher'
|
||||
|
||||
|
||||
// querydsl
|
||||
implementation "com.querydsl:querydsl-jpa:${queryDslVersion}:jakarta"
|
||||
annotationProcessor "com.querydsl:querydsl-apt:${queryDslVersion}:jakarta"
|
||||
annotationProcessor "jakarta.annotation:jakarta.annotation-api"
|
||||
annotationProcessor "jakarta.persistence:jakarta.persistence-api"
|
||||
// p6spy
|
||||
implementation 'com.github.gavlyukovskiy:p6spy-spring-boot-starter:1.9.0'
|
||||
}
|
||||
|
||||
tasks.named('test') {
|
||||
useJUnitPlatform()
|
||||
}
|
||||
|
||||
// querydsl
|
||||
def querydslDir = "$buildDir/generated/querydsl"
|
||||
|
||||
sourceSets {
|
||||
main.java.srcDirs += [ querydslDir ]
|
||||
}
|
||||
|
||||
tasks.withType(JavaCompile) {
|
||||
options.annotationProcessorGeneratedSourcesDirectory = file(querydslDir)
|
||||
}
|
||||
|
||||
clean.doLast {
|
||||
file(querydslDir).deleteDir()
|
||||
}
|
||||
|
Reference in New Issue
Block a user