fix check-protobuf-stability (#18682)

Currently fails in the presence of release candidates.
This commit is contained in:
Gary Verhaegen 2024-03-08 18:22:09 +01:00 committed by GitHub
parent b95140e9bb
commit b978f97970
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -74,7 +74,7 @@ USAGE
readonly BRANCH_SUFFIX="${TARGET#release/}"
readonly MINOR_VERSION="${BRANCH_SUFFIX%.x}"
readonly NEXT_MINOR_VERSION=$(semver bump minor "$MINOR_VERSION.0")
readonly STABLE_TAGS=($(git tag | grep "v.*" | grep -v "snapshot" | sort -V))
readonly STABLE_TAGS=($(git tag | grep -P '^v\d+\.\d+\.\d+$' | sort -V))
LATEST_STABLE_TAG="$(
for TAG in "${STABLE_TAGS[@]}"; do
if [[ $(semver compare "${TAG#v}" "$NEXT_MINOR_VERSION") == "-1" ]]; then