Skip to content

Commit

Permalink
Adding a variable to set the next development version on Bamboo
Browse files Browse the repository at this point in the history
  • Loading branch information
wikumChamith committed Nov 11, 2024
1 parent 2f906f0 commit fcaf576
Showing 1 changed file with 10 additions and 1 deletion.
11 changes: 10 additions & 1 deletion bamboo-specs/bamboo.yml
Original file line number Diff line number Diff line change
Expand Up @@ -257,6 +257,7 @@ Release:
set +x
export OMRS_VERSION=${bamboo.maven.release.version}
export NEW_DEV_VERSION=${maven.development.version}
export IMAGE=${bamboo.docker.image.name}:${OMRS_VERSION}
export DEV_IMAGE=${bamboo.docker.image.name}:${OMRS_VERSION}-dev
export BUILD_IMAGE=${bamboo.docker.image.id}
Expand Down Expand Up @@ -299,8 +300,16 @@ Release:
(
echo "Updating the main branch to a new SNAPSHOT version"
git push
echo "Setting the next development version"
if [ -z "$NEW_DEV_VERSION" ]; then
docker run --rm -v m2-repo:/root/.m2/repository -v $(pwd):/openmrs_core \
${DEV_IMAGE} mvn versions:set -DnextSnapshot=true -DgenerateBackupPoms=false
else
docker run --rm -v m2-repo:/root/.m2/repository -v $(pwd):/openmrs_core \
${DEV_IMAGE} mvn versions:set -DnextSnapshot=true -DgenerateBackupPoms=false
${DEV_IMAGE} mvn versions:set -DnewVersion=${NEW_DEV_VERSION} -DgenerateBackupPoms=false
fi
git commit -am "Setting new SNAPSHOT version"
git push
Expand Down

0 comments on commit fcaf576

Please sign in to comment.