This repository was archived by the owner on Apr 4, 2025. It is now read-only.
File tree Expand file tree Collapse file tree 4 files changed +27
-11
lines changed
Expand file tree Collapse file tree 4 files changed +27
-11
lines changed Original file line number Diff line number Diff line change @@ -106,19 +106,15 @@ pipeline {
106106
107107 environment {
108108 ARTIFACTORY = credentials(' 02bd1690-b54f-4c9f-819d-a77cb7a9822c' )
109- SONATYPE = credentials(' oss-token ' )
109+ SONATYPE = credentials(' oss-login ' )
110110 KEYRING = credentials(' spring-signing-secring.gpg' )
111111 PASSPHRASE = credentials(' spring-gpg-passphrase' )
112112 }
113113
114114 steps {
115115 script {
116- // Warm up this plugin quietly before using it.
117- sh ' MAVEN_OPTS="-Duser.name=jenkins -Duser.home=/tmp/jenkins-home" ./mvnw -q org.apache.maven.plugins:maven-help-plugin:2.1.1:evaluate -Dexpression=project.version'
118-
119- // Extract project's version number
120116 PROJECT_VERSION = sh(
121- script : ' MAVEN_OPTS="-Duser.name=jenkins -Duser.home=/tmp/jenkins-home" ./mvnw org.apache.maven.plugins:maven-help-plugin:2.1.1:evaluate -Dexpression=project. version -o | grep -v INFO ' ,
117+ script : " ci/ version.sh " ,
122118 returnStdout : true
123119 ). trim()
124120
@@ -134,6 +130,12 @@ pipeline {
134130
135131 if (RELEASE_TYPE == ' release' ) {
136132 sh " PROFILE=central USERNAME=${ SONATYPE_USR} PASSWORD=${ SONATYPE_PSW} ci/build-and-deploy-to-maven-central.sh ${ PROJECT_VERSION} "
133+
134+ slackSend(
135+ color : (currentBuild. currentResult == ' SUCCESS' ) ? ' good' : ' danger' ,
136+ channel : ' #spring-session-bot' ,
137+ message : " @here Spring Session for MongoDB ${ PROJECT_VERSION} is staged on Sonatype awaiting closure and release." )
138+
137139 } else {
138140 sh " PROFILE=${ RELEASE_TYPE} ci/build-and-deploy-to-artifactory.sh"
139141 }
Original file line number Diff line number Diff line change @@ -21,5 +21,5 @@ MAVEN_OPTS="-Duser.name=jenkins -Duser.home=/tmp/jenkins-home" ./mvnw \
2121 -Dmaven.test.skip=true \
2222 -Dgpg.passphrase=${PASSPHRASE} \
2323 -Dgpg.secretKeyring=${GNUPGHOME} /secring.gpg \
24- -DstagingDescription=" Releasing ${PROJECT_VERSION} " \
24+ -DstagingDescription=" Releasing Spring Session for MongoDB ${PROJECT_VERSION} " \
2525 clean deploy -B
Original file line number Diff line number Diff line change 1+ #! /bin/bash
2+
3+ set -euo pipefail
4+
5+ RAW_VERSION=` MAVEN_OPTS=" -Duser.name=jenkins -Duser.home=/tmp/jenkins-home" ./mvnw \
6+ org.apache.maven.plugins:maven-help-plugin:3.2.0:evaluate \
7+ -Dexpression=project.version -q -DforceStdout`
8+
9+ # Split things up
10+ VERSION_PARTS=($RAW_VERSION )
11+
12+ # Grab the last part, which is the actual version number.
13+ echo ${VERSION_PARTS[${#VERSION_PARTS[@]} -1]}
14+
Original file line number Diff line number Diff line change 582582 <extensions >true</extensions >
583583 <configuration >
584584 <serverId >sonatype</serverId >
585- <nexusUrl >https://oss.sonatype.org/</nexusUrl >
586- <autoReleaseAfterClose >true </autoReleaseAfterClose >
585+ <nexusUrl >https://s01. oss.sonatype.org/</nexusUrl >
586+ <autoReleaseAfterClose >false </autoReleaseAfterClose >
587587 <keepStagingRepositoryOnFailure >true</keepStagingRepositoryOnFailure >
588- <skipStagingRepositoryClose >false </skipStagingRepositoryClose >
588+ <skipStagingRepositoryClose >true </skipStagingRepositoryClose >
589589 </configuration >
590590 </plugin >
591591 </plugins >
626626 <distributionManagement >
627627 <repository >
628628 <id >sonatype</id >
629- <url >https://oss.sonatype.org/service/local/staging/deploy/maven2/</url >
629+ <url >https://s01. oss.sonatype.org/ /service/local/staging/deploy/maven2/</url >
630630 </repository >
631631 </distributionManagement >
632632
You can’t perform that action at this time.
0 commit comments