Skip to content

Commit

Permalink
#2 - Chore: QueryDSL 의존성 추가, 설정 작업
Browse files Browse the repository at this point in the history
  • Loading branch information
ahah525 committed Oct 19, 2022
1 parent f722e61 commit 0f8b46e
Showing 1 changed file with 34 additions and 0 deletions.
34 changes: 34 additions & 0 deletions 1Week_Mission/mutbooks/build.gradle
Original file line number Diff line number Diff line change
@@ -1,7 +1,17 @@
// querydsl 추가
buildscript {
ext {
queryDslVersion = "5.0.0"
}
}

plugins {
id 'org.springframework.boot' version '2.7.4'
id 'io.spring.dependency-management' version '1.0.14.RELEASE'
id 'java'

//querydsl 추가
id "com.ewerk.gradle.plugins.querydsl" version "1.0.10"
}

group = 'com.example'
Expand Down Expand Up @@ -36,8 +46,32 @@ dependencies {
implementation 'org.springframework.boot:spring-boot-starter-validation'
// Gmail SMTP
implementation 'org.springframework.boot:spring-boot-starter-mail'

//querydsl 추가
implementation "com.querydsl:querydsl-jpa:${queryDslVersion}"
annotationProcessor "com.querydsl:querydsl-apt:${queryDslVersion}"
}

tasks.named('test') {
useJUnitPlatform()
}

//querydsl 추가 시작
def querydslDir = "$buildDir/generated/querydsl"

querydsl {
jpa = true
querydslSourcesDir = querydslDir
}

sourceSets {
main.java.srcDir querydslDir
}

configurations {
querydsl.extendsFrom compileClasspath
}

compileQuerydsl {
options.annotationProcessorPath = configurations.querydsl
}

0 comments on commit 0f8b46e

Please sign in to comment.