Skip to content

Commit 9281db6

Browse files
committed
HSEARCH-5400 Add an extra parameter to control release stage: Upload/Release
1 parent e500688 commit 9281db6

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

ci/release/Jenkinsfile

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -37,6 +37,11 @@ pipeline {
3737
defaultValue: false,
3838
description: 'If true, just simulate the release, without pushing any commits or tags, and without uploading any artifacts or documentation.'
3939
)
40+
booleanParam(
41+
name: 'RELEASE_PUBLISH_AUTOMATICALLY',
42+
defaultValue: true,
43+
description: 'If true, staging repository will get closed and published automatically, otherwise the artifacts will only be uploaded and the publishing (releasing the staging repository) has to be performed manually at Maven Central portal.'
44+
)
4045
}
4146
stages {
4247
stage('Release') {
@@ -61,6 +66,9 @@ pipeline {
6166
def releaseVersion = Version.parseReleaseVersion(params.RELEASE_VERSION)
6267
def developmentVersion = Version.parseDevelopmentVersion(params.DEVELOPMENT_VERSION)
6368
env.JRELEASER_DRY_RUN = params.RELEASE_DRY_RUN
69+
if (!params.RELEASE_PUBLISH_AUTOMATICALLY) {
70+
env.JRELEASER_DEPLOY_MAVEN_MAVENCENTRAL_STAGE='UPLOAD'
71+
}
6472
echo "Performing full release for version ${releaseVersion.toString()}"
6573

6674
withMaven(mavenSettingsConfig: params.RELEASE_DRY_RUN ? null : 'ci-hibernate.deploy.settings.maven',

0 commit comments

Comments
 (0)