This repository has been archived by the owner on Aug 25, 2022. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 61
/
build.gradle
118 lines (97 loc) · 3 KB
/
build.gradle
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
118
version = "1.0.0"
description = "spring boot starters"
buildscript {
ext {
springBootVersion = "2.0.4.RELEASE"
kotlinVersion = "1.2.60"
dokkaVersion = "0.9.+"
junitVersion = "5.0.2"
jdkVersion = "1.8"
}
repositories {
mavenLocal()
maven {
name "aliyun maven central"
url "http://maven.aliyun.com/nexus/content/groups/public"
}
maven {
name "spring repo milestone"
url "https://repo.spring.io/milestone"
}
mavenCentral()
jcenter()
}
dependencies {
classpath "org.springframework.boot:spring-boot-gradle-plugin:$springBootVersion"
classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlinVersion"
classpath "org.jetbrains.kotlin:kotlin-allopen:$kotlinVersion"
classpath "org.jetbrains.dokka:dokka-gradle-plugin:$dokkaVersion"
classpath "org.junit.platform:junit-platform-gradle-plugin:1.0.2"
}
}
apply plugin: "idea"
idea {
project {
languageLevel = "$jdkVersion"
}
module {
downloadJavadoc = true
downloadSources = true
}
}
configure(subprojects) {
group = "com.manerfan.springboot"
ext {
gradleScriptDir = "${rootProject.projectDir}/gradle"
}
apply from: "${gradleScriptDir}/docs.gradle"
apply plugin: "java"
apply plugin: "java-library"
sourceCompatibility = "$jdkVersion"
targetCompatibility = "$jdkVersion"
apply plugin: "kotlin"
apply plugin: "kotlin-spring"
apply plugin: "org.junit.platform.gradle.plugin"
compileKotlin {
kotlinOptions.jvmTarget = "$jdkVersion"
}
compileTestKotlin {
kotlinOptions.jvmTarget = "$jdkVersion"
}
repositories {
mavenLocal()
maven {
name "aliyun maven central"
url "http://maven.aliyun.com/nexus/content/groups/public"
}
maven {
name "spring repo milestone"
url "https://repo.spring.io/milestone"
}
mavenCentral()
jcenter()
}
// apply plugin: "org.springframework.boot"
apply plugin: "io.spring.dependency-management"
dependencyManagement {
imports {
mavenBom("org.springframework.boot:spring-boot-dependencies:$springBootVersion")
}
}
dependencies {
implementation "org.jetbrains.kotlin:kotlin-reflect:$kotlinVersion"
implementation "org.jetbrains.kotlin:kotlin-stdlib-jdk8:$kotlinVersion"
testCompile "org.springframework.boot:spring-boot-starter-test"
testCompile "org.junit.jupiter:junit-jupiter-api:$junitVersion"
testCompile "org.junit.jupiter:junit-jupiter-engine:$junitVersion"
}
compileJava.dependsOn(processResources)
[compileJava, javadoc, compileTestJava]*.options*.encoding = "UTF-8"
test {
forkEvery = 5
maxParallelForks = Runtime.runtime.availableProcessors() / 2
}
}
task wrapper(type: Wrapper) {
gradleVersion = "4.2"
}