fix: pick the previous release by version, not reachability (#31897)

fix: pick the previous release by version, not reachability (#31884)

(cherry picked from commit 75b4e33143)

Co-authored-by: bo0tzz <git@bo0tzz.me>
This commit is contained in:
immich-push-o-matic[bot]
2026-09-29 14:41:00 +00:00
committed by GitHub
co-authored by bo0tzz
parent bc78992af4
commit 935855a510
+3 -3
View File
@@ -144,11 +144,11 @@ jobs:
PRERELEASE: ${{ needs.tag.outputs.rc }}
BRANCH: ${{ github.ref_name }}
run: |
exclude=()
tags=$(git -c versionsort.suffix=-rc tag --list 'v[0-9]*' --sort=-v:refname)
if [[ "${PRERELEASE}" != 'true' ]]; then
exclude=(--exclude '*-rc*')
tags=$(grep -v -- '-rc.' <<< "${tags}")
fi
previous=$(git describe --tags --abbrev=0 --match 'v*' "${exclude[@]}" --exclude "${TAG}" HEAD)
previous=$(grep -A1 -xF "${TAG}" <<< "${tags}" | tail -1)
echo "generating notes from ${previous}"
gh release create "${TAG}" \