-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathbuild.gradle
More file actions
66 lines (53 loc) · 1.81 KB
/
build.gradle
File metadata and controls
66 lines (53 loc) · 1.81 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
// C.2.1. 인코딩 지정
// java plugin의 속성에서 인코딩을 지정 -> Settings-File Encodings에서 UTF-8 설정
plugins {
id 'org.springframework.boot' version '2.5.3'
id 'io.spring.dependency-management' version '1.0.11.RELEASE'
id 'java'
// C.2.2. .editorconfig 플러그인 설정
id 'org.ec4j.editorconfig' version '0.0.3'
// C.2.3. Checkstyle 플러그인 설정
id 'checkstyle'
}
// C.2.1. java UTF-8 encoding
compileJava.options.encoding = 'UTF-8'
compileTestJava.options.encoding = 'UTF-8'
// C.2.2. .editorconfig 플러그인 설정
editorconfig {
excludes = ['build']
}
check.dependsOn editorconfigCheck
// C.2.3. Checkstyle 플러그인 설정
checkstyle {
maxWarnings = 0 // 규칙이 어긋나는 코드가 하나라도 있을 경우 빌드 fail을 내고 싶다면 이 선언을 추가한다.
configFile = file("${rootDir}/naver-chestyle-rules.xml")
configProperties = ["suppressionFile": "${rootDir}/naver-checkstyle-suppressions.xml"]
toolVersion = "8.24" // checkstyle 버전 8.24 이상 선언
}
group = 'spring'
version = '0.0.1-SNAPSHOT'
sourceCompatibility = '11'
//lombok 설정 추가 시작
configurations {
compileOnly {
extendsFrom annotationProcessor
}
}
//lombok 설정 추가 끝
repositories {
mavenCentral()
}
dependencies {
implementation 'org.springframework.boot:spring-boot-starter'
implementation 'javax.inject:javax.inject:1'
//lombok 라이브러리 추가 시작
compileOnly 'org.projectlombok:lombok'
annotationProcessor 'org.projectlombok:lombok'
testCompileOnly 'org.projectlombok:lombok'
testAnnotationProcessor 'org.projectlombok:lombok'
//lombok 라이브러리 추가 끝
testImplementation 'org.springframework.boot:spring-boot-starter-test'
}
test {
useJUnitPlatform()
}