File tree Expand file tree Collapse file tree 3 files changed +20
-4
lines changed Expand file tree Collapse file tree 3 files changed +20
-4
lines changed Original file line number Diff line number Diff line change @@ -135,7 +135,10 @@ pipeline {
135
135
// update changelog from JIRA
136
136
// tags the version
137
137
// changes the version to the provided development version
138
- withEnv([" BRANCH=${ env.GIT_BRANCH} " ]) {
138
+ withEnv([
139
+ " BRANCH=${ env.GIT_BRANCH} " ,
140
+ " DISABLE_REMOTE_GRADLE_CACHE=true"
141
+ ]) {
139
142
sh " .release/scripts/prepare-release.sh ${ env.PROJECT} ${ env.RELEASE_VERSION} ${ env.DEVELOPMENT_VERSION} "
140
143
}
141
144
}
@@ -161,7 +164,11 @@ pipeline {
161
164
sshagent([' ed25519.Hibernate-CI.github.com' , ' hibernate.filemgmt.jboss.org' , ' hibernate-ci.frs.sourceforge.net' ]) {
162
165
// performs documentation upload and Sonatype release
163
166
// push to github
164
- sh " .release/scripts/publish.sh ${ env.SCRIPT_OPTIONS} ${ env.PROJECT} ${ env.RELEASE_VERSION} ${ env.DEVELOPMENT_VERSION} ${ env.GIT_BRANCH} "
167
+ withEnv([
168
+ " DISABLE_REMOTE_GRADLE_CACHE=true"
169
+ ]) {
170
+ sh " .release/scripts/publish.sh ${ env.SCRIPT_OPTIONS} ${ env.PROJECT} ${ env.RELEASE_VERSION} ${ env.DEVELOPMENT_VERSION} ${ env.GIT_BRANCH} "
171
+ }
165
172
}
166
173
}
167
174
}
Original file line number Diff line number Diff line change 11
11
12
12
ext {
13
13
isCiEnvironment = isJenkins() || isGitHubActions() || isGenericCi()
14
- populateRemoteBuildCache = getSetting( " POPULATE_REMOTE" ). isPresent()
14
+ populateRemoteBuildCache = isEnabled( " POPULATE_REMOTE" )
15
+ useRemoteCache = ! isEnabled( " DISABLE_REMOTE_GRADLE_CACHE" )
15
16
}
16
17
17
18
private static boolean isJenkins () {
@@ -36,6 +37,14 @@ static java.util.Optional<String> getSetting(String name) {
36
37
return java.util.Optional . ofNullable(sysProp);
37
38
}
38
39
40
+ static boolean isEnabled (String setting ) {
41
+ if ( System . getenv(). hasProperty( setting ) ) {
42
+ return true
43
+ }
44
+
45
+ return System . hasProperty( setting )
46
+ }
47
+
39
48
gradleEnterprise {
40
49
server = ' https://ge.hibernate.org'
41
50
Original file line number Diff line number Diff line change @@ -279,7 +279,7 @@ buildCache {
279
279
enabled = ! settings. ext. isCiEnvironment
280
280
}
281
281
remote(HttpBuildCache ) {
282
- enabled = true
282
+ enabled = settings . ext . useRemoteCache
283
283
push = settings. ext. populateRemoteBuildCache
284
284
url = ' https://ge.hibernate.org/cache/'
285
285
}
You can’t perform that action at this time.
0 commit comments