We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent e1a5415 commit 055a29cCopy full SHA for 055a29c
1 file changed
.github/workflows/release-on-pr-merge.yml
@@ -91,8 +91,10 @@ jobs:
91
git fetch --tags origin main || true
92
git checkout main || true
93
94
- # Calculate version for release
95
- LATEST_TAG=$(git describe --tags --abbrev=0 2>/dev/null || echo "v0.0.0")
+ # Calculate version for release - only consider semver tags (vMAJOR.MINOR.PATCH)
+ # to avoid picking up helm chart tags like vcloudcost-exporter-1.1.0
96
+ LATEST_TAG=$(git tag -l 'v[0-9]*.[0-9]*.[0-9]*' | sort -V | tail -1)
97
+ LATEST_TAG="${LATEST_TAG:-v0.0.0}"
98
VERSION="${LATEST_TAG#v}"
99
IFS='.' read -r MAJOR MINOR PATCH <<< "$VERSION"
100
0 commit comments