-
Notifications
You must be signed in to change notification settings - Fork 6
/
build.gradle
124 lines (104 loc) · 2.62 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
import com.axelor.gradle.support.ChangelogSupport
buildscript {
ext.repos = {
mavenCentral() {
content { excludeGroupByRegex "com\\.axelor.*" }
}
maven {
url 'https://plugins.gradle.org/m2/'
content { excludeGroupByRegex "com\\.axelor.*" }
}
maven { url 'https://repository.axelor.com/nexus/repository/maven-public/' }
}
ext.aopVersion = '7.2.1'
repositories repos
buildscript.repositories repos
dependencies {
classpath "com.axelor:axelor-gradle:${aopVersion}"
classpath "com.adarshr:gradle-test-logger-plugin:2.+"
}
}
repositories repos
buildscript.repositories repos
apply from: "version.gradle"
apply plugin: "com.axelor.app"
apply plugin: 'com.adarshr.test-logger'
apply plugin: ChangelogSupport
try {
tasks.named("spotlessCheck")
} catch (UnknownTaskException ignored) {
apply from: './gradle/style.gradle'
}
testlogger {
theme 'mocha'
}
sourceCompatibility = JavaVersion.VERSION_11
targetCompatibility = JavaVersion.VERSION_11
group = "com.axelor.addons"
description "Axelor Message Module"
axelor {
title "Axelor Message"
description "Axelor Message Module"
}
dependencies {
implementation "com.squareup.okhttp3:okhttp:4.12.0"
implementation 'org.reflections:reflections:0.10.2'
if (findProject(":modules:axelor-utils") != null) {
api project(":modules:axelor-utils")
} else {
implementation "com.axelor.addons:axelor-utils:3.2.1"
}
testImplementation 'org.awaitility:awaitility:4.2.0'
}
changelog {
version = baseVersion
output.set(file("CHANGELOG.md"))
inputPath.set(file("changelogs/unreleased"))
types.set(["Feature", "Change", "Deprecate", "Remove", "Fix", "Security"])
header.set("${version.get()} (${new Date().format("yyyy-MM-dd")})")
}
//
// Publish
//
apply plugin: 'maven-publish'
ext {
mavenUsername = project.findProperty("addonsMavenUsername")
mavenPassword = project.findProperty("addonsMavenPassword")
}
publishing {
repositories {
maven {
def repoPath = project.hasProperty("finalRelease")
? "maven-releases"
: "maven-snapshots"
name = "maven"
url = "https://repository.axelor.com/nexus/repository/" + repoPath
credentials {
username = project.mavenUsername
password = project.mavenPassword
}
}
}
}
/*
* Jacoco
*/
apply plugin: 'jacoco'
jacoco {
toolVersion = '0.8.11'
}
jacocoTestReport {
reports {
xml.enabled true
}
}
test {
useJUnitPlatform()
// report is always generated after tests run
finalizedBy jacocoTestReport
maxHeapSize = '1G'
}
jacocoTestReport {
// tests are required to run before generating the report
dependsOn test
}