-
Notifications
You must be signed in to change notification settings - Fork 7
Expand file tree
/
Copy pathbuild.gradle
More file actions
executable file
·79 lines (68 loc) · 1.84 KB
/
build.gradle
File metadata and controls
executable file
·79 lines (68 loc) · 1.84 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
plugins {
id 'java'
id 'org.jetbrains.intellij' version '1.17.0'
// id "org.jetbrains.kotlin.jvm" version "1.3.41"
}
group 'com.zhang'
version '2024.3-PLUS6'
repositories {
mavenCentral()
}
dependencies {
implementation 'com.alibaba:druid:1.2.8'
implementation 'dom4j:dom4j:1.6.1'
// slf4j 高版本的ideaIC已经自带实现,不需要额外引用,否则会因为冲突导致报错.
// implementation 'org.slf4j:slf4j-api:2.0.0-alpha1'
// implementation 'org.slf4j:slf4j-jdk14:2.0.0-alpha1'
// 加载本地依赖
implementation fileTree(dir:'src/main/resources/libs',includes:['*.jar'])
// 系统
testImplementation 'org.junit.jupiter:junit-jupiter-api:5.6.0'
testRuntimeOnly 'org.junit.jupiter:junit-jupiter-engine'
}
configurations.configureEach {
// 必须排除,否则dom4j冲突
exclude group: 'xml-apis', module: 'xml-apis'
}
// See https://github.com/JetBrains/gradle-intellij-plugin/
intellij {
// version.set("2019.3.5")
// version.set("2024.1.4")
version.set("2024.3.2.2")
plugins = ['java', 'gradle']
// updateSinceUntilBuild默认true,会指定until-build,这里手动关闭,表示向上兼容
updateSinceUntilBuild.set(false)
}
java {
sourceCompatibility = JavaVersion.VERSION_17
}
apply {
"java"
"terminal"
"ant"
}
test {
useJUnitPlatform()
}
sourceSets {
main {
java {
// 忽略所有的 src/main/java/test目录
exclude 'test/**'
}
resources {
// 打包忽略目录和文件
exclude 'img/**'
exclude 'libs/**'
exclude 'libsource/**'
exclude 'icons/mybatis/**'
exclude 'icons/scanner.vsdx'
}
}
}
tasks.withType(JavaCompile) {
options.encoding = "UTF-8"
}
buildPlugin {
buildSearchableOptions.enabled = false
}