-
Notifications
You must be signed in to change notification settings - Fork 0
/
build.gradle
78 lines (69 loc) · 2.28 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
buildscript {
repositories {
mavenCentral()
}
dependencies {
classpath 'org.springframework.boot:spring-boot-gradle-plugin:1.5.19.RELEASE'
}
}
plugins {
id 'java'
}
apply plugin: 'war'
apply plugin: 'org.springframework.boot'
group = 'com.winbaoxian.testng'
version = '2.0.0'
sourceCompatibility = '1.8'
repositories {
mavenLocal()
maven { url "http://192.168.180.191:8081/nexus/content/repositories/public" }
maven { url "http://192.168.180.191:8081/nexus/content/repositories/snapshots/" }
maven { url 'https://maven.aliyun.com/repository/public' }
maven {
credentials {
username 'YqEg7E'
password 'kqPhqT56Db'
}
url 'https://repo.rdc.aliyun.com/repository/77327-snapshot-eSlStJ/'
}
mavenCentral()
}
dependencies {
compileOnly 'org.projectlombok:lombok:1.16.22'
compile 'org.springframework.boot:spring-boot-starter-web'
compile 'mysql:mysql-connector-java:8.0.15'
compile 'org.mongodb:mongo-java-driver:3.10.1'
compile 'com.aliyun.oss:aliyun-sdk-oss:2.4.0'
compile 'com.winbaoxian.testng:wintestng-core:2.0.0-SNAPSHOT'
compile "com.winbaoxian.module:win-security:1.0.0-SNAPSHOT"
compile 'com.winbaoxian.module:win-cas:1.0.0-SNAPSHOT'
compile 'org.testng:testng:6.14.3'
compile 'com.alibaba:easyexcel:2.2.3'
testCompile 'org.springframework.boot:spring-boot-starter-test'
}
def isWindows() {
return org.gradle.internal.os.OperatingSystem.current().isWindows()
}
String apidocCmd = isWindows() ? 'apidoc.cmd' : 'apidoc'
task apidocs(type: Exec, description: '执行生成apidoc文档操作') {
workingDir './'
def docCommand = [apidocCmd, '-o', './build/apidocs', '-f', 'java', '--debug', 'true']
commandLine docCommand
}
def defaultProperty(propertyName, defaultValue) {
return hasProperty(propertyName) ? project[propertyName] : defaultValue
}
ext{
env = defaultProperty('env', 'dev')
}
gradle.taskGraph.whenReady { taskGraph ->
//编译的时候放入资源
sourceSets {
main {
resources {
srcDirs = ["src/main/resources", "src/main/resources/${env}"]
includes = ["application.yml", "*.xml", "*.dic", "*.txt", "*.properties", "templates/**", "static/**"]
}
}
}
}