releases/tools/transition_series.sh
Előd Illés af8b2d1f3c [tools] Do not transition tempest plugins
The series transition script simply lists all deliverables, including
tempest plugins, which are branchless, hence no need to transition
them to Unmaintained/EOL at all.

Change-Id: Id35aaf710008a8a0d776bc9d3f0a6a12fd452dbf
2024-10-21 14:16:02 +02:00

51 lines
1.2 KiB
Bash
Executable File

#!/bin/bash
#
# Convenience wrapper transition a release cycle to its next stable
# phase.
TOOLSDIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )"
BASEDIR=$(dirname $TOOLSDIR)
#source $TOOLSDIR/functions
if [[ $# -lt 2 ]]; then
echo "Usage: $(basename $0) <series> <tag>"
echo ""
echo "<tag> either 'em', 'eom' or 'eol'"
exit 1
fi
series="$1"
tag="$2"
if [[ -z "$VIRTUAL_ENV" ]]; then
if [[ ! -d $BASEDIR/.tox/venv ]]; then
(cd $BASEDIR && tox -e venv --notest)
fi
source $BASEDIR/.tox/venv/bin/activate
fi
echo "Finding deliverables for $series series..."
deliverables=$(list-deliverables --series $series --except-type tempest-plugin)
errors=()
for deliverable in $deliverables; do
echo "Adding $series-$tag tag for $deliverable..."
new-release $series $deliverable $tag
if [[ $? -ne 0 ]]; then
echo ""
echo "!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!"
echo "$deliverable failed to update"
echo "!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!"
echo ""
errors+=("$deliverable")
fi
done
if [[ ${#errors[@]} -ne 0 ]]; then
echo ""
echo "Errors adding tags to some deliverables. Check the following:"
echo " ${errors[@]}"
exit 1
fi