Merge pull request #7004 from zmstone/chore-check-the-right-base-vsn

chore: exclude alpha beta and rc tags when checking app.src vsn bump
This commit is contained in:
Zaiming (Stone) Shi 2022-02-15 15:24:47 +01:00 committed by GitHub
commit df4f528381
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 10 additions and 1 deletions

View File

@ -1,7 +1,16 @@
#!/usr/bin/env bash
set -euo pipefail
latest_release=$(git describe --abbrev=0 --tags)
## compare to the latest 5.0 release version tag:
## but do not include alpha, beta and rc versions
latest_release="$(git describe --abbrev=0 --tags --match '[v|e]5.0*' --exclude '*beta*' --exclude '*alpha*' --exclude '*rc*' || echo 'nomatch')"
if [ "$latest_release" = 'nomatch' ]; then
echo "No base release found, skipping app vsn checks"
exit 0
fi
echo "Compare base: $latest_release"
bad_app_count=0