Fix rc version check in release script

This commit is contained in:
Daniel Perez 2019-03-31 21:14:46 +01:00
parent 5e2468a16d
commit 401fcb4f31

View File

@ -71,10 +71,10 @@ fi
if ! (echo "$new_version" | grep -i "rc"); then
# Make sure an RC already exists when tagging a major or minor version
new_major_and_minor=$(echo "$new_version" | cut -d. -f1,2)
if ! git tag | grep "^$new_major_and_minor.[0-9]*$" > /dev/null; then
if ! git tag | grep "^v$new_major_and_minor.[0-9]*$" > /dev/null; then
# If the major and minor versions don't already exist, make sure this release
# is preceded by an RC release
if ! git tag | grep "^$new_major_and_minor.[0-9]*-rc[0-9]*$" > /dev/null; then
if ! git tag | grep "^v$new_major_and_minor.[0-9]*-rc[0-9]*$" > /dev/null; then
echo >&2 "ERROR: New major and minor versions must be preceded by an RC version"
exit 1
fi