From 18134896abe1d3ffa500033d3ffe1faff9c3f81e Mon Sep 17 00:00:00 2001 From: rsynek Date: Fri, 10 Jul 2026 11:36:44 +0200 Subject: [PATCH] ci: make version update idempotent --- .github/scripts/change_versions.sh | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/.github/scripts/change_versions.sh b/.github/scripts/change_versions.sh index 8a78a56d70..a5d0c0a942 100755 --- a/.github/scripts/change_versions.sh +++ b/.github/scripts/change_versions.sh @@ -2,13 +2,8 @@ # Expects the following environment variables to be set: # $NEW_VERSION (Example: "1.2.0") -# This will fail the Maven build if the version is not available. -# Thankfully, this is not the case (yet) in this project. -# If/when it happens, this needs to be replaced by a manually provided version, -# as scanning the text of the POM would be unreliable. + echo " New version: $NEW_VERSION" -./mvnw versions:set -Dfull -Dproperty=revision -DnewVersion="$NEW_VERSION" -Drevision="$NEW_VERSION" -DgenerateBackupPoms=false -# replaces the parent revision which is not updated by the previous command sed -i "0,/<\/revision>/s/.*<\/revision>/$NEW_VERSION<\/revision>/" pom.xml sed -i "0,/<\/revision>/s/.*<\/revision>/$NEW_VERSION<\/revision>/" service/facade/service-parent/pom.xml git add -u