-
Notifications
You must be signed in to change notification settings - Fork 3
Expand file tree
/
Copy pathbuild.gradle
More file actions
87 lines (72 loc) · 1.75 KB
/
build.gradle
File metadata and controls
87 lines (72 loc) · 1.75 KB
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
//buildscript {
// repositories {
// maven {
// url "https://plugins.gradle.org/m2/"
// }
// }
// dependencies {
// classpath "io.github.gradle-nexus:publish-plugin:1.1.0"
// }
//}
plugins {
id "io.github.gradle-nexus.publish-plugin" version "1.1.0"
id 'net.researchgate.release' version '3.0.2'
}
if (JavaVersion.current() != JavaVersion.VERSION_1_8) {
throw new UnsupportedOperationException(
"Please use JDK 8 to compile this project, current: ${JavaVersion.current()}"
)
}
subprojects {
apply plugin: "java-library"
repositories {
mavenLocal()
mavenCentral()
}
sourceCompatibility = JavaVersion.VERSION_1_7
tasks.withType(JavaCompile) {
options.encoding = 'UTF-8'
}
compileTestJava {
sourceCompatibility = JavaVersion.VERSION_1_7
}
test {
useJUnitPlatform()
testLogging {
events "failed"
exceptionFormat "full"
}
}
}
nexusPublishing {
repositories {
mavenCentral {
nexusUrl = uri("https://oss.sonatype.org/service/local/")
snapshotRepositoryUrl = uri("https://oss.sonatype.org/content/repositories/snapshots/")
username = project.findProperty("ossrhUsername")
password = project.findProperty("ossrhPassword")
}
}
}
configure([
project(":aptools"), project(":lombok-ext"), project(":reflection-config-generator")
]){
apply from: "${rootProject.rootDir}/nexus.gradle"
}
release {
project.ext.set("release.useAutomaticVersion", true)
git {
requireBranch.set("master")
}
failOnCommitNeeded = false
failOnPublishNeeded = false
failOnUnversionedFiles = false
buildTasks = []
}
confirmReleaseVersion.doLast {
def f = file("${project.projectDir}/README.md")
def text = f.text
f.withWriter { w ->
w << text.replaceAll("(:\\ )*\\d+\\.\\d+\\.\\d+", "\$1${version}")
}
}