fix(release): handle missing previous tag in release workflow
CI / Build (push) Has been cancelled
CI / Test (push) Has been cancelled

This commit is contained in:
Hein
2026-06-29 11:59:56 +02:00
parent dd91e7ed5a
commit 30801c747a
2 changed files with 17 additions and 4 deletions
+1 -1
View File
@@ -63,7 +63,7 @@ jobs:
TAG="${{ github.event.inputs.tag || github.ref_name }}"
API="${GITHUB_API_URL}/repos/${GITHUB_REPOSITORY}/releases"
PREV_TAG=$(git tag --sort=-version:refname | grep -v "^${TAG}$" | head -1)
PREV_TAG=$(git tag --sort=-version:refname | { grep -v "^${TAG}$" || true; } | head -1)
if [ -n "$PREV_TAG" ]; then
RANGE="${PREV_TAG}..${TAG}"
else