Skip to content

Commit d99c588

Browse files
ci: don't fail release if version didn't change (#18)
Signed-off-by: Adrian Cole <[email protected]>
1 parent 4be630b commit d99c588

File tree

1 file changed

+6
-4
lines changed

1 file changed

+6
-4
lines changed

build-bin/helm/helm_prepare

+6-4
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,7 @@
1717

1818
trigger_tag=${1?trigger_tag is required. Ex release-1.2.3}
1919
release_version=$(build-bin/git/version_from_trigger_tag release- ${trigger_tag})
20+
latest_app_version=${2?latest_app_version is required. Ex 4.5.6}
2021
release_branch=${3:-master}
2122

2223
# Checkout master, as we release from master, not a tag ref
@@ -32,14 +33,15 @@ if [ "$commit_local_release_branch" != "$commit_remote_release_branch" ]; then
3233
fi
3334

3435
# Update appVersion
35-
latest_app_version=${2?latest_app_version is required. Ex 4.5.6}
3636
sh -c "sed -i 's/appVersion\:\s[0-9.]\+/appVersion\: ${latest_app_version}/g' ./charts/zipkin/Chart.yaml"
3737

3838
# Update version
3939
sh -c "sed -i 's/version\:\s[0-9.]\+/version\: ${release_version}/g' ./charts/zipkin/Chart.yaml"
4040

4141
# Commit changes to ./charts/zipkin/Chart.yaml
42-
git add ./charts/zipkin/Chart.yaml && git commit -m "chore: prepare chart release ${release_version}"
42+
git add ./charts/zipkin/Chart.yaml
4343

44-
# Push the changes in ./charts/zipkin/Chart.yaml to the release branch
45-
git push origin ${release_branch}
44+
if git commit -m "release: updates for ${release_version}"; then
45+
# Push the changes in ./charts/zipkin/Chart.yaml to the release branch
46+
git push origin ${release_branch}
47+
fi

0 commit comments

Comments
 (0)