-
Notifications
You must be signed in to change notification settings - Fork 47
/
build.gradle
92 lines (82 loc) · 2.4 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
plugins {
id 'java-library'
id 'org.dmfs.gver' version '0.18.0'
id 'io.github.gradle-nexus.publish-plugin' version '1.1.0' apply false
}
sourceCompatibility = JavaVersion.VERSION_1_8
targetCompatibility = JavaVersion.VERSION_1_8
gver {
issueTracker GitHub {
repo = "dmfs/lib-recur"
if (project.hasProperty("GITHUB_API_TOKEN")) {
accessToken = GITHUB_API_TOKEN
}
}
changes {
are none when {
affects only(matches(~/.*\.md/))
}
are major when {
commitMessage contains(~/(?i)#(major|break(ing)?)\b/)
}
are minor when {
commitMessage contains(~/(?i)#(?<issue>\d+)\b/) {
where("issue") { isIssue { labeled "enhancement" } }
}
}
are patch when {
commitMessage contains(~/(?i)#(?<issue>\d+)\b/) {
where("issue") { isIssue { labeled "bug" } }
}
}
are minor when {
commitMessage contains("#feature\\b")
}
otherwise patch
}
preReleases {
on ~/main|master/ use { "beta" }
on ~/(.*\/)?(?<name>.*)/ use { "alpha-${group('name')}.1" }
}
releaseBranchPattern ~/main|master$/
}
configurations {
pom
}
apply from: 'publish.gradle'
apply from: 'jacoco.gradle'
allprojects {
group 'org.dmfs'
repositories {
mavenCentral()
}
}
if (project.hasProperty('SONATYPE_USERNAME') && project.hasProperty('SONATYPE_PASSWORD')) {
apply plugin: 'io.github.gradle-nexus.publish-plugin'
nexusPublishing {
repositories {
sonatype {
username = SONATYPE_USERNAME
password = SONATYPE_PASSWORD
}
}
}
}
dependencies {
compileOnly libs.srcless.annotations
annotationProcessor libs.srcless.processors
compileOnly 'org.eclipse.jdt:org.eclipse.jdt.annotation:2.2.600'
testImplementation 'org.junit.jupiter:junit-jupiter-api:5.9.0'
testRuntimeOnly 'org.junit.jupiter:junit-jupiter-engine:5.9.0'
api 'org.dmfs:rfc5545-datetime:0.3'
api libs.jems2
testImplementation project("lib-recur-hamcrest")
testImplementation project("lib-recur-confidence")
testImplementation libs.jems2.testing
testImplementation libs.jems2.confidence
testImplementation libs.confidence.core
testImplementation libs.confidence.engine
}
test {
useJUnitPlatform()
}