From 64659d7763f5c10bce79d00e821ab943d4b3b623 Mon Sep 17 00:00:00 2001 From: donghyunkim Date: Mon, 22 Jan 2024 18:46:25 +0900 Subject: [PATCH] =?UTF-8?q?feat!:=20querydsl=20=EB=9D=BC=EC=9D=B4=EB=B8=8C?= =?UTF-8?q?=EB=9F=AC=EB=A6=AC=20=EC=B6=94=EA=B0=80?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- build.gradle | 26 +++++++++++++++++++++++++- 1 file changed, 25 insertions(+), 1 deletion(-) diff --git a/build.gradle b/build.gradle index 90b6d7ca..722391df 100644 --- a/build.gradle +++ b/build.gradle @@ -3,6 +3,8 @@ plugins { id 'org.springframework.boot' version '2.7.10' id 'io.spring.dependency-management' version '1.0.15.RELEASE' id 'checkstyle' + //querydsl 추가 + id "com.ewerk.gradle.plugins.querydsl" version "1.0.10" } group = 'com.cafegory' @@ -40,6 +42,11 @@ dependencies { implementation 'com.h2database:h2' + //querydsl 추가 + implementation 'com.querydsl:querydsl-jpa' + implementation 'com.querydsl:querydsl-jpa:5.0.0' + implementation 'com.querydsl:querydsl-apt:5.0.0' + testCompileOnly 'org.projectlombok:lombok' testAnnotationProcessor 'org.projectlombok:lombok' @@ -67,4 +74,21 @@ checkstyle { } checkstyleMain.source = fileTree('src/main/java') -checkstyleTest.source = fileTree('src/test/java') \ No newline at end of file +checkstyleTest.source = fileTree('src/test/java') + +//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 +} +//querydsl 추가 끝 \ No newline at end of file