Skip to content
Snippets Groups Projects
Commit 53eaa7cb authored by Andrea Valassi's avatar Andrea Valassi
Browse files

Improve (pre-)release candidate checks

parent 6ce185bb
No related branches found
No related tags found
1 merge request!1Add Ubuntu 2404 (noble numbat)
......@@ -17,13 +17,23 @@ function is_rc_tag()
fi
local _rva=$1
local _tag=$2
local _rev=$(echo $_tag | cut -d '.' -f3- | cut -d '-' -f2)
local _rev=$(echo $_tag | cut -d '.' -f3- | cut -d '-' -f2-)
if [ "${_rev#0.rc}" != "${_rev}" ] || [ "${_rev#0.prc}" != "${_rev}" ]; then
echo "WARNING: tag ${tag} is a (pre-)release-candidate"
printf "\n"
eval ${_rva}=true
elif [ "${_rev#0_rc}" != "${_rev}" ] || [ "${_rev#0_prc}" != "${_rev}" ] ||
[ "${_rev#0-rc}" != "${_rev}" ] || [ "${_rev#0-prc}" != "${_rev}" ] ||
elif [ "${_rev#*_rc}" != "${_rev}" ] || [ "${_rev#*_prc}" != "${_rev}" ] ||
[ "${_rev#*-rc}" != "${_rev}" ] || [ "${_rev#*-prc}" != "${_rev}" ] ||
[ "${_rev#*.rc}" != "${_rev}" ] || [ "${_rev#*.prc}" != "${_rev}" ] ||
[ "${_rev#9rc}" != "${_rev}" ] || [ "${_rev#9prc}" != "${_rev}" ] ||
[ "${_rev#8rc}" != "${_rev}" ] || [ "${_rev#8prc}" != "${_rev}" ] ||
[ "${_rev#7rc}" != "${_rev}" ] || [ "${_rev#7prc}" != "${_rev}" ] ||
[ "${_rev#6rc}" != "${_rev}" ] || [ "${_rev#6prc}" != "${_rev}" ] ||
[ "${_rev#5rc}" != "${_rev}" ] || [ "${_rev#5prc}" != "${_rev}" ] ||
[ "${_rev#4rc}" != "${_rev}" ] || [ "${_rev#4prc}" != "${_rev}" ] ||
[ "${_rev#3rc}" != "${_rev}" ] || [ "${_rev#3prc}" != "${_rev}" ] ||
[ "${_rev#2rc}" != "${_rev}" ] || [ "${_rev#2prc}" != "${_rev}" ] ||
[ "${_rev#1rc}" != "${_rev}" ] || [ "${_rev#1prc}" != "${_rev}" ] ||
[ "${_rev#0rc}" != "${_rev}" ] || [ "${_rev#0prc}" != "${_rev}" ]; then
echo "ERROR! Tag ${tag} is an invalid tag"
echo "ERROR! Use -0.rcXX or -0.prcXX for (pre-)release candidates"
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment