Skip to content

Commit

Permalink
build/#131: build.gradle -> build.gradle.kts 로 변경
Browse files Browse the repository at this point in the history
  • Loading branch information
JiwonDev committed Jan 5, 2024
1 parent 3d482d2 commit 3b42450
Show file tree
Hide file tree
Showing 53 changed files with 597 additions and 396 deletions.
11 changes: 0 additions & 11 deletions account-api/account-application/build.gradle

This file was deleted.

18 changes: 18 additions & 0 deletions account-api/account-application/build.gradle.kts
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
tasks.jar {
enabled = true
}

tasks.bootJar {
enabled = false
}

plugins {
id("org.springframework.boot")
id("io.spring.dependency-management")
}

dependencies {
implementation(project(":account-api:account-domain"))
implementation(project(":common"))
implementation("org.springframework.boot:spring-boot-starter-data-jpa")
}
8 changes: 0 additions & 8 deletions account-api/account-domain/build.gradle

This file was deleted.

16 changes: 16 additions & 0 deletions account-api/account-domain/build.gradle.kts
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
tasks.jar {
enabled = true
}

tasks.bootJar {
enabled = false
}

dependencies {
implementation(project(":common"))
implementation("jakarta.persistence:jakarta.persistence-api:3.1.0")
implementation("org.hibernate:hibernate-core:6.3.2.Final")
testImplementation("org.assertj:assertj-core")
testImplementation("org.junit.jupiter:junit-jupiter-api")
testRuntimeOnly("org.junit.jupiter:junit-jupiter-engine")
}
17 changes: 0 additions & 17 deletions account-api/account-infrastructure/build.gradle

This file was deleted.

25 changes: 25 additions & 0 deletions account-api/account-infrastructure/build.gradle.kts
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
tasks.jar {
enabled = true
}

tasks.bootJar {
enabled = false
}

plugins {
id("org.springframework.boot")
id("io.spring.dependency-management")
}

dependencies {
implementation(project(":account-api:account-domain"))
implementation(project(":common"))
implementation("io.jsonwebtoken:jjwt-api:0.12.3")
implementation("io.jsonwebtoken:jjwt-impl:0.12.3")
implementation("io.jsonwebtoken:jjwt-jackson:0.12.3")
implementation("org.springframework.boot:spring-boot-starter-web")
implementation("org.springframework.boot:spring-boot-starter-data-jpa")
implementation("org.springframework.boot:spring-boot-starter-security")
testImplementation("org.springframework.boot:spring-boot-starter-test")
annotationProcessor("org.springframework.boot:spring-boot-configuration-processor")
}
16 changes: 0 additions & 16 deletions account-api/account-presentation/build.gradle

This file was deleted.

23 changes: 23 additions & 0 deletions account-api/account-presentation/build.gradle.kts
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
tasks.jar {
enabled = true
}

tasks.bootJar {
enabled = false
}

plugins {
id("org.springframework.boot")
id("io.spring.dependency-management")
}

dependencies {
implementation(project(":account-api:account-application"))
implementation(project(":common"))
implementation("org.springdoc:springdoc-openapi-ui:1.6.6")
implementation("org.springframework.boot:spring-boot-starter-web")
implementation("org.springframework.boot:spring-boot-starter-security")
implementation("org.springframework.boot:spring-boot-starter-validation")
testImplementation("org.springframework.security:spring-security-test")
testImplementation("org.springframework.boot:spring-boot-starter-test")
}
51 changes: 0 additions & 51 deletions app/build.gradle

This file was deleted.

56 changes: 56 additions & 0 deletions app/build.gradle.kts
Original file line number Diff line number Diff line change
@@ -0,0 +1,56 @@
tasks.bootJar {
enabled = true
}

plugins {
id("org.springframework.boot")
id("io.spring.dependency-management")
kotlin("plugin.jpa")
kotlin("plugin.allopen")
kotlin("plugin.spring") apply false
}

dependencies {
implementation(project(":notification-api:notification-presentation"))
implementation(project(":notification-api:notification-application"))
implementation(project(":notification-api:notification-domain"))
implementation(project(":notification-api:notification-infrastructure"))

implementation(project(":account-api:account-presentation"))
implementation(project(":account-api:account-application"))
implementation(project(":account-api:account-domain"))
implementation(project(":account-api:account-infrastructure"))

implementation(project(":order-api:order-presentation"))
implementation(project(":order-api:order-application"))
implementation(project(":order-api:order-domain"))
implementation(project(":order-api:order-infrastructure"))

implementation(project(":payment-api:payment-presentation"))
implementation(project(":payment-api:payment-application"))
implementation(project(":payment-api:payment-domain"))
implementation(project(":payment-api:payment-infrastructure"))

implementation(project(":product-api:product-presentation"))
implementation(project(":product-api:product-application"))
implementation(project(":product-api:product-domain"))
implementation(project(":product-api:product-infrastructure"))

implementation(project(":query-api"))
implementation(project(":common"))

implementation("org.springdoc:springdoc-openapi-ui:1.6.6")
implementation("org.springdoc:springdoc-openapi-security:1.6.6")
implementation("org.springframework.boot:spring-boot-starter-web")
implementation("org.springframework.boot:spring-boot-starter-data-jpa")
implementation("org.springframework.boot:spring-boot-starter-security")
implementation("org.springframework.boot:spring-boot-starter-validation")
implementation("org.springframework.boot:spring-boot-starter-amqp")
implementation("it.ozimov:embedded-redis:0.7.2")
testImplementation("it.ozimov:embedded-redis:0.7.2")
runtimeOnly("com.mysql:mysql-connector-j")
implementation("org.flywaydb:flyway-mysql")
testImplementation("com.h2database:h2")
testImplementation("com.navercorp.fixturemonkey:fixture-monkey-starter:0.3.5")
testImplementation("org.springframework.boot:spring-boot-starter-test")
}
23 changes: 5 additions & 18 deletions build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -8,24 +8,18 @@ buildscript {
}

dependencies {
classpath("org.yaml:snakeyaml:1.28")
classpath("org.jetbrains.kotlin:kotlin-allopen:1.8.20")
classpath("org.jetbrains.kotlin:kotlin-gradle-plugin:1.6.0-RC2")
}
}

plugins {
id("org.springframework.boot") version "3.1.2"
id("io.spring.dependency-management") version "1.1.2"
id("org.jetbrains.kotlin.plugin.allopen") version "1.8.20"
id("org.jetbrains.kotlin.plugin.noarg") version "1.8.20"
jacoco
idea

kotlin("jvm") version "1.8.20"
kotlin("plugin.spring") version "1.8.20"
kotlin("plugin.jpa") version "1.8.20"
kotlin("kapt") version "1.8.20"
kotlin("jvm")
kotlin("kapt")
kotlin("plugin.noarg")
}

java {
Expand All @@ -39,14 +33,6 @@ configurations {
}
}

tasks.jar {
enabled = true
}

tasks.bootJar {
enabled = false
}

allprojects {
repositories {
maven("https://plugins.gradle.org/m2/")
Expand Down Expand Up @@ -74,7 +60,8 @@ subprojects {
}

noArg {
annotation("com.kidsworld.core.annotation.NoArgsConstructor")
// spring, jpa 가 아니라서 플러그인이 적용되지 않는 코드에 noArg 적용하는 용도로 사용한다.
annotation("kr.flab.movieon.common.annotation.NoArgsConstructor")
}

dependencies {
Expand Down
29 changes: 29 additions & 0 deletions buildSrc/build.gradle.kts
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
plugins {
`kotlin-dsl`
}

repositories {
mavenCentral()
maven {
url = uri("https://plugins.gradle.org/m2/")
}
}

/**
* 전체 프로젝트의 gradle plugin 버전을 지정 한다.
*/
object PluginVersion {
const val KOTLIN = "1.8.20"
const val SPRING_BOOT = "3.1.2"
const val SPRING_DEPENDENCY_MANAGEMENT = "1.1.2"
const val ASCIIDOCTOR = "3.3.2"
}

dependencies {
implementation("org.jetbrains.kotlin:kotlin-gradle-plugin:${PluginVersion.KOTLIN}")
implementation("org.jetbrains.kotlin:kotlin-allopen:${PluginVersion.KOTLIN}")
implementation("org.jetbrains.kotlin:kotlin-noarg:${PluginVersion.KOTLIN}")
implementation("org.springframework.boot:spring-boot-gradle-plugin:${PluginVersion.SPRING_BOOT}")
implementation("io.spring.gradle:dependency-management-plugin:${PluginVersion.SPRING_DEPENDENCY_MANAGEMENT}")
implementation("org.asciidoctor:asciidoctor-gradle-jvm:${PluginVersion.ASCIIDOCTOR}")
}
4 changes: 3 additions & 1 deletion buildSrc/main/kotlin/Version.kt
Original file line number Diff line number Diff line change
@@ -1 +1,3 @@
object Version
object Version {
val jakartaPersistenceApiVersion = "3.1.0"
}
4 changes: 0 additions & 4 deletions common/build.gradle

This file was deleted.

12 changes: 12 additions & 0 deletions common/build.gradle.kts
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
tasks.jar {
enabled = true
}

tasks.bootJar {
enabled = false
}

dependencies {
testImplementation("org.junit.jupiter:junit-jupiter-api")
testRuntimeOnly("org.junit.jupiter:junit-jupiter-engine")
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
package kr.flab.movieon.common.annotation

annotation class NoArgsConstructor
4 changes: 1 addition & 3 deletions gradle.properties
Original file line number Diff line number Diff line change
@@ -1,10 +1,8 @@
### Application Version ###
applicationVersion=0.0.1

### Project Groups ###
projectGroups=kr.flab.movieon

### Gradle Settings ###
org.gradle.parallel=true
org.gradle.caching=true
org.gradle.jvmargs=-Dfile.encoding=UTF-8
org.gradle.jvmargs=-Dfile.encoding=UTF-8 -Xms2048m -Xmx2048m
13 changes: 0 additions & 13 deletions notification-api/notification-application/build.gradle

This file was deleted.

Loading

0 comments on commit 3b42450

Please sign in to comment.