-
Notifications
You must be signed in to change notification settings - Fork 0
/
build.gradle
130 lines (114 loc) · 2.84 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
119
120
121
122
123
124
125
126
127
128
129
130
buildscript {
ext {
springBootVersion = '2.7.18'
}
repositories {
maven { url "http://maven.weoa.com/nexus/content/groups/public/"; }
}
dependencies {
classpath("org.springframework.boot:spring-boot-gradle-plugin:${springBootVersion}")
classpath 'com.github.sherter.googlejavaformatgradleplugin:google-java-format-gradle-plugin:0.9-SNAPSHOT'
}
}
apply plugin: 'idea'
apply plugin: 'java'
apply plugin: 'org.springframework.boot'
apply plugin: 'io.spring.dependency-management'
apply plugin: 'com.github.sherter.google-java-format'
group = 'com.webank'
version = '1.0.6'
sourceCompatibility = '1.8'
configurations {
compileOnly {
extendsFrom annotationProcessor
}
}
repositories {
//mavenCentral()
maven {
url "http://maven.weoa.com/nexus/content/groups/public/"
}
//maven { url "https://maven.aliyun.com/repository/public" }
}
dependencies {
implementation 'org.springframework.boot:spring-boot-starter-web'
implementation 'org.springframework:spring-web:5.3.34'
implementation 'org.springframework.boot:spring-boot-starter'
implementation 'org.springframework.boot:spring-boot-starter-validation'
implementation 'org.springframework.boot:spring-boot-starter-aop'
compileOnly 'org.projectlombok:lombok'
annotationProcessor 'org.projectlombok:lombok'
testCompileOnly('org.projectlombok:lombok')
testAnnotationProcessor('org.projectlombok:lombok')
testImplementation 'org.springframework.boot:spring-boot-starter-test'
implementation('cn.hutool:hutool-all:5.8.27')
implementation('org.yaml:snakeyaml:2.0')
// java sdk
implementation ("org.fisco-bcos.java-sdk:fisco-bcos-java-sdk:3.6.0")
}
bootJar {
destinationDir file('dist')
archiveName project.name +'_4396' + '.jar'
from('src/main/java'){
include '**/*.xml'
}
exclude '**/*.properties'
exclude '**/*.yml'
exclude '**/*.xml'
}
test {
useJUnitPlatform()
}
clean {
delete file('dist')
}
task aomp {
doLast {
copy {
from file('src/main/resources/aomp/start_uat.sh')
from file('src/main/resources/aomp/start.sh')
from file('src/main/resources/aomp/stop.sh')
into 'dist'
}
copy {
from file('src/main/resources/aomp/logback-spring.xml')
from file('src/main/resources/aomp/application.yml')
into 'dist/config'
}
}
}
task dev {
doLast {
copy {
from file('config')
into 'dist/config/'
}
copy {
from file('src/main/resources/' )
include('**/*.yml')
into 'dist/config/'
}
copy {
from file('src/main/resources/')
include('**/*.sh')
into 'dist/'
}
}
}
tasks.withType(Copy) {
filesMatching("**/*.sql") {
duplicatesStrategy = DuplicatesStrategy.INCLUDE
}
filesMatching("**/*.yml") {
duplicatesStrategy = DuplicatesStrategy.INCLUDE
}
filesMatching("**/*.sh") {
duplicatesStrategy = DuplicatesStrategy.INCLUDE
}
}
googleJavaFormat {
toolVersion = '1.7'
options style: 'AOSP'
source = sourceSets*.allJava
include '**/*.java'
}