forked from AfterShip/aftership-sdk-java
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathbuild.gradle
123 lines (99 loc) · 2.89 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
buildscript {
ext {
jvmVersion = '1.8'
junitPlatformVersion = '1.6.2'
junitEngineVersion = '5.6.2'
mockitoVersion = '3.3.3'
okhttpVersion = '4.6.0'
gsonVersion = '2.8.6'
lombokVersion = '1.18.10'
}
repositories {
mavenCentral()
}
dependencies {
}
}
allprojects {
group 'com.aftership'
version '2.0.8'
repositories {
mavenCentral()
}
tasks.withType(JavaCompile) {
options.encoding = 'UTF-8'
sourceCompatibility = jvmVersion
targetCompatibility = jvmVersion
}
}
subprojects {
apply plugin: 'idea'
apply plugin: 'java'
apply plugin: 'checkstyle'
checkstyle {
toolVersion = "8.8"
ignoreFailures = false
showViolations = true
configFile = file("${project.rootDir}/checkstyle.xml")
}
dependencies {
testCompile "org.junit.platform:junit-platform-launcher:${junitPlatformVersion}"
testCompile "org.junit.jupiter:junit-jupiter-engine:${junitEngineVersion}"
testCompile "org.junit.vintage:junit-vintage-engine:${junitEngineVersion}"
testCompile "org.mockito:mockito-core:${mockitoVersion}"
testImplementation "com.squareup.okhttp3:mockwebserver:${okhttpVersion}"
annotationProcessor "org.projectlombok:lombok:${lombokVersion}"
compileOnly "org.projectlombok:lombok:${lombokVersion}"
testAnnotationProcessor "org.projectlombok:lombok:${lombokVersion}"
testCompileOnly "org.projectlombok:lombok:${lombokVersion}"
}
task sourcesJar(type: Jar) {
from sourceSets.main.allJava
classifier = 'sources'
}
task javadocJar(type: Jar) {
from javadoc
classifier = 'javadoc'
}
javadoc {
options.encoding = "UTF-8"
}
test.useTestNG()
test {
useJUnitPlatform()
}
}
project(':aftership-sdk') {
apply from: "${project.rootDir}/publishing.gradle"
apply plugin: 'jacoco'
dependencies {
implementation "com.squareup.okhttp3:okhttp:${okhttpVersion}"
implementation "com.google.code.gson:gson:${gsonVersion}"
}
jar {
archivesBaseName = "aftership-sdk"
}
jacocoTestReport {
reports {
xml.enabled true
xml.destination file("${buildDir}/reports/jacoco/report.xml")
html.enabled true
html.destination file("${buildDir}/jacocoHtml")
csv.enabled false
}
afterEvaluate {
classDirectories.from = files(classDirectories.files.collect {
fileTree(dir: it, exclude: ['com/aftership/sdk/model/**'])
})
}
}
}
project(':aftership-sample'){
dependencies {
//compile project(':aftership-sdk')
implementation "com.aftership:aftership-sdk:2.0.8"
}
jar {
archivesBaseName = "aftership-sample"
}
}