This repository has been archived by the owner on May 24, 2023. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 1
/
build.gradle
94 lines (77 loc) · 3.14 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
buildscript {
// we need to share Spring boot version across buildscript and the rest of the application. Unfortunately, this
// is only the one known way:
// https://discuss.gradle.org/t/how-to-access-project-ext-variables-from-within-buildscript-section/5706/3
ext.springBoot = '1.5.9.RELEASE'
ext.grgitVersion = '2.3.0'
ext.testLoggerVersion = '2.1.1'
ext.dockerPackageVersion = '3.2.5'
repositories {
jcenter()
mavenCentral()
maven {
url "https://plugins.gradle.org/m2/"
}
}
dependencies {
classpath("org.springframework.boot:spring-boot-gradle-plugin:$springBoot")
classpath("org.ajoberstar:grgit:$grgitVersion")
classpath("com.adarshr:gradle-test-logger-plugin:$testLoggerVersion")
}
}
repositories {
jcenter()
mavenCentral()
}
apply plugin: 'java'
apply plugin: 'idea'
apply plugin: 'org.springframework.boot'
apply plugin: 'com.adarshr.test-logger'
targetCompatibility = 1.8
sourceCompatibility = 1.8
version = '0.4.0-DEV' // this will be replaced by git tag version, if available
apply from: "$rootDir/gradle/version-resolver.gradle"
apply from: "$rootDir/gradle/test-config.gradle"
apply from: "$rootDir/gradle/idea-config.gradle"
apply from: "$rootDir/gradle/set-library-version.gradle"
jar {
version = project.version
archiveName = "${rootProject.name}.jar"
manifest {
attributes("Implementation-Title": rootProject.name,
"Implementation-Version": version)
}
}
final depVersions = [
springBoot : ext.springBoot,
commercetoolsSdkJvm: '2.0.0',
paypalPlusSdk : '1.14.0',
guava : '30.1.1-jre',
apacheCollections : '4.4',
// tests
assertJ : '3.20.2',
systemRules : '1.19.0',
beforeTestRunner : '0.1.0'
]
dependencies {
compile "org.springframework.boot:spring-boot-starter-web:${depVersions.springBoot}"
compile "com.paypal.sdk:rest-api-sdk:${depVersions.paypalPlusSdk}"
compile "com.commercetools.sdk.jvm.core:commercetools-models:${depVersions.commercetoolsSdkJvm}"
compile "com.commercetools.sdk.jvm.core:commercetools-java-client:${depVersions.commercetoolsSdkJvm}"
compile "com.commercetools.sdk.jvm.core:commercetools-convenience:${depVersions.commercetoolsSdkJvm}"
compile "com.google.guava:guava:${depVersions.guava}"
compile "org.apache.commons:commons-collections4:${depVersions.apacheCollections}"
testCommonCompile("org.springframework.boot:spring-boot-starter-test:${depVersions.springBoot}") {
exclude group: 'org.assertj', module: 'assertj-core' // below override the default outdated one with the latest
}
testCommonCompile "org.assertj:assertj-core:${depVersions.assertJ}"
testIntegrationCompile "com.github.stefanbirkner:system-rules:${depVersions.systemRules}"
testIntegrationCompile "org.bitbucket.radistao.test:before-after-spring-test-runner:${depVersions.beforeTestRunner}"
}
tasks.withType(JavaCompile) {
options.compilerArgs << "-Xlint:unchecked" << "-Xlint:deprecation"
}
testlogger {
theme 'mocha'
slowThreshold 20000
}