forked from pegasystems/pega-alertanalyzer
-
Notifications
You must be signed in to change notification settings - Fork 0
/
build.gradle
52 lines (44 loc) · 1.69 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
buildscript {
repositories {
mavenLocal()
jcenter()
maven {
url "https://plugins.gradle.org/m2/"
}
maven {
url artifactoryURL
credentials {
username = artifactoryUser
password = artifactoryPassword
}
}
}
dependencies {
classpath 'org.ajoberstar:gradle-git:1.4.2'
classpath 'net.ltgt.gradle:gradle-errorprone-plugin:0.0.13'
classpath 'com.github.jengelman.gradle.plugins:shadow:2.0.1'
}
}
// must be set prior to 'release-opinion' plugin getting applied
// as they are magically used behind the scenes.
rootProject.ext.setProperty('release.stage', releaseStage.trim())
rootProject.ext.setProperty('release.scope', releaseScope.trim())
apply plugin: 'org.ajoberstar.release-opinion'
release {
def credentials = new org.ajoberstar.grgit.Credentials(releaseUsername, releasePassword)
grgit = org.ajoberstar.grgit.Grgit.open(dir: project.rootDir.absolutePath, creds: credentials)
versionStrategy org.ajoberstar.gradle.git.release.opinion.Strategies.FINAL
defaultVersionStrategy = org.ajoberstar.gradle.git.release.opinion.Strategies.SNAPSHOT
tagStrategy {
generateMessage = { version -> "Version ${->project.version}" }
}
}
// Ensure the following tasks are run as part of releasing a new version.
def releaseTasks = ['clean', 'build', uploadTask]
if (Boolean.valueOf(publishGithubPages).booleanValue()) {
releaseTasks << 'gitPublishPush'
}
tasks.release.dependsOn(releaseTasks.collect { task ->
subprojects.collect { ":" + it.name + ":" + task }.flatten()
}.flatten())
apply from: "$rootDir/gradle/projects.gradle"