Repository navigation
Expand file tree
/
Copy pathbuild.gradle
More file actions
117 lines (103 loc) · 4.33 KB
/
Copy pathbuild.gradle
File metadata and controls
117 lines (103 loc) · 4.33 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
plugins {
id 'java'
id 'org.springframework.boot' version '4.1.0'
id 'io.spring.dependency-management' version '1.1.7'
id 'com.diffplug.spotless' version '6.25.0'
}
group = 'kr.bi'
version = '0.0.1-SNAPSHOT'
description = 'Goto'
java {
toolchain {
languageVersion = JavaLanguageVersion.of(21)
}
}
spotless {
java {
removeUnusedImports()
palantirJavaFormat()
endWithNewline()
}
}
repositories {
mavenCentral()
}
def loadDotenv(File dotenvFile) {
if (!dotenvFile.exists()) {
return [:]
}
return dotenvFile.readLines()
.collect { it.trim() }
.findAll { it && !it.startsWith('#') && it.contains('=') }
.collectEntries { line ->
def parts = line.split('=', 2)
def key = parts[0].trim().replaceFirst('^export\\s+', '')
def value = parts[1].trim()
if ((value.startsWith('"') && value.endsWith('"'))
|| (value.startsWith("'") && value.endsWith("'"))) {
value = value.substring(1, value.length() - 1)
}
if (!key || !value) {
return [:]
}
[(key): value]
}
}
ext {
set('springCloudAwsVersion', '4.0.2')
set('springdocOpenapiVersion', '3.0.3')
set('testcontainersVersion', '1.21.4')
set('querydslVersion', '5.1.0')
set('firebaseAdminVersion', '9.10.0')
}
dependencyManagement {
imports {
mavenBom "io.awspring.cloud:spring-cloud-aws-dependencies:${springCloudAwsVersion}"
mavenBom "org.testcontainers:testcontainers-bom:${testcontainersVersion}"
}
}
dependencies {
implementation 'org.springframework.boot:spring-boot-starter-batch'
implementation 'org.springframework.boot:spring-boot-starter-batch-jdbc'
implementation 'org.springframework.boot:spring-boot-starter-actuator'
implementation 'org.springframework.boot:spring-boot-starter-data-jpa'
implementation 'org.springframework.boot:spring-boot-starter-data-redis'
implementation 'org.hibernate.orm:hibernate-spatial'
implementation "com.querydsl:querydsl-jpa:${querydslVersion}:jakarta"
implementation 'org.springframework.boot:spring-boot-starter-flyway'
implementation 'org.springframework.boot:spring-boot-starter-jackson'
implementation 'org.springframework.boot:spring-boot-starter-security'
implementation 'org.springframework.boot:spring-boot-starter-validation'
implementation 'org.springframework.boot:spring-boot-starter-restclient'
implementation 'org.springframework.boot:spring-boot-starter-webmvc'
implementation 'io.awspring.cloud:spring-cloud-aws-starter-parameter-store'
implementation 'io.awspring.cloud:spring-cloud-aws-starter-s3'
implementation "org.springdoc:springdoc-openapi-starter-webmvc-ui:${springdocOpenapiVersion}"
implementation "com.google.firebase:firebase-admin:${firebaseAdminVersion}"
compileOnly 'org.projectlombok:lombok'
annotationProcessor 'org.projectlombok:lombok'
testCompileOnly 'org.projectlombok:lombok'
testAnnotationProcessor 'org.projectlombok:lombok'
runtimeOnly 'org.flywaydb:flyway-database-postgresql'
annotationProcessor 'org.springframework.boot:spring-boot-configuration-processor'
annotationProcessor "com.querydsl:querydsl-apt:${querydslVersion}:jakarta"
annotationProcessor 'jakarta.annotation:jakarta.annotation-api'
annotationProcessor 'jakarta.persistence:jakarta.persistence-api'
runtimeOnly 'org.postgresql:postgresql'
testImplementation 'org.springframework.batch:spring-batch-test'
testImplementation 'org.springframework.boot:spring-boot-starter-data-jpa-test'
testImplementation 'org.springframework.boot:spring-boot-starter-restclient-test'
testImplementation 'org.springframework.boot:spring-boot-starter-webmvc-test'
testImplementation 'org.springframework.boot:spring-boot-test-autoconfigure'
testImplementation 'org.springframework.boot:spring-boot-testcontainers'
testImplementation 'org.testcontainers:junit-jupiter'
testImplementation 'org.testcontainers:postgresql'
testRuntimeOnly 'org.junit.platform:junit-platform-launcher'
}
tasks.named('test') {
useJUnitPlatform()
environment loadDotenv(file('.env'))
}
tasks.named('bootRun') {
environment loadDotenv(file('.env'))
}