SKALE-2202 fix codacy warnings

parent c52f1df5
......@@ -4,19 +4,19 @@ BRANCH=$1
VERSION=$2
CONTAINER=$3
if [ -z $BRANCH ]
if [ -z "$BRANCH" ]
then
echo "A branch is not set."
exit 1
fi
if [ -z $VERSION ]
if [ -z "$VERSION" ]
then
echo "The base version is not set."
exit 1
fi
if [ -z $CONTAINER ]
if [ -z "$CONTAINER" ]
then
echo "The base container is not set."
exit 1
......@@ -24,17 +24,17 @@ fi
git fetch --tags
if [ $BRANCH = "master" ]
if [ "$BRANCH" = "master" ]
then
echo $VERSION
echo "$VERSION"
exit 0
fi
LABEL="develop"
if [ $BRANCH = "stable" ]
if [ "$BRANCH" = "stable" ]
then
LABEL="stable"
elif [ $BRANCH = "beta" ]
elif [ "$BRANCH" = "beta" ]
then
LABEL="beta"
fi
......@@ -42,9 +42,9 @@ fi
for (( VERSION_NUMBER=0; ; VERSION_NUMBER++ ))
do
RESULT_VERSION="$CONTAINER:$VERSION-$LABEL.$VERSION_NUMBER"
if ! [ $(git tag -l ?$RESULT_VERSION) ]
if ! [ "$(git tag -l ?"$RESULT_VERSION")" ]
then
echo $RESULT_VERSION
echo "$RESULT_VERSION"
break
fi
done
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment