diff --git a/.github/workflows/charts-release.yaml b/.github/workflows/charts-release.yaml index 12d25eaccff..db6b49fdaa0 100644 --- a/.github/workflows/charts-release.yaml +++ b/.github/workflows/charts-release.yaml @@ -67,15 +67,10 @@ jobs: run: |- TAG="" if RELEASES_JSON="$(curl -fsSL \ - https://api.github.com/repos/trueforge-org/forgetool/releases)"; then - TAG="$(jq -r '[.[] - | select(.prerelease == true) - | .tag_name - | select(test("^(forgetool-)?v[0-9]+\\.[0-9]+\\.[0-9]+-ALPHA[0-9]+$")) - | {tag: ., alpha: (capture("ALPHA(?[0-9]+)$").n | tonumber)} - ] | if length > 0 then max_by(.alpha).tag else empty end' <<< "${RELEASES_JSON}")" + https://api.github.com/repos/trueforge-org/forgetool/releases/latest)"; then + TAG="$(jq -r '.tag_name // empty' <<< "${RELEASES_JSON}")" fi - [ -n "${TAG}" ] && [ "${TAG}" != "null" ] || TAG="v4.0.0-ALPHA28" + [ -n "${TAG}" ] && [ "${TAG}" != "null" ] || { echo "Failed to determine latest forgetool release tag"; exit 1; } VERSION="${TAG#v}" VERSION="${VERSION#forgetool-v}" case "$(uname -m)" in