-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathbuild.gradle
55 lines (44 loc) · 1.97 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
plugins {
id 'java'
}
group 'space.mmty'
version '1.0-SNAPSHOT'
jar {
manifest {
// 指定启动类
attributes 'Main-Class': 'space.mmty.server.ServerStarter'
}
from {
// 将compile的内容收集过来
configurations.compile.collect { it.isDirectory() ? it : zipTree(it) }
}
}
repositories {
// maven { url 'https://repo1.maven.org/maven2/' }
maven { url 'https://maven.aliyun.com/nexus/content/groups/public/' }
maven { url 'https://mirrors.cloud.tencent.com/nexus/repository/maven-public/' }
maven { url 'https://maven.springframework.org/release' }
mavenCentral()
}
dependencies {
// https://mvnrepository.com/artifact/org.apache.commons/commons-lang3
compile group: 'org.apache.commons', name: 'commons-lang3', version: '3.11'
// https://mvnrepository.com/artifact/com.alibaba/fastjson
compile group: 'com.alibaba', name: 'fastjson', version: '1.2.75'
// https://mvnrepository.com/artifact/org.apache.httpcomponents/httpclient
compile(group: 'org.apache.httpcomponents', name: 'httpclient', version: '4.5.13') {
// 这些依赖将在下面单独引入
exclude(group: 'org.apache.httpcomponents', module: 'httpcore')
exclude(group: 'commons-codec', module: 'commons-codec')
exclude(group: 'commons-logging', module: 'commons-logging')
}
// https://mvnrepository.com/artifact/org.apache.httpcomponents/httpcore
compile group: 'org.apache.httpcomponents', name: 'httpcore', version: '4.4.13'
// https://mvnrepository.com/artifact/commons-codec/commons-codec
compile group: 'commons-codec', name: 'commons-codec', version: '1.15'
// https://mvnrepository.com/artifact/commons-logging/commons-logging
compile group: 'commons-logging', name: 'commons-logging', version: '1.2'
// https://mvnrepository.com/artifact/log4j/log4j
compile group: 'log4j', name: 'log4j', version: '1.2.17'
testCompile group: 'junit', name: 'junit', version: '4.12'
}