Skip to content

Commit

Permalink
scripts: fix version check
Browse files Browse the repository at this point in the history
Signed-off-by: Steffen Vogel <post@steffenvogel.de>
  • Loading branch information
stv0g committed Oct 6, 2022
1 parent 59e068d commit 7657110
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions scripts/get_cunicu.sh
Expand Up @@ -131,12 +131,12 @@ function checkDesiredVersion() {
function checkInstalledVersion() {
if [[ -f "${INSTALL_DIR}/${BINARY_NAME}" ]]; then
local installed_version=$("${INSTALL_DIR}/${BINARY_NAME}" version -s)
if [[ "v${installed_version}" == "${TAG}" ]]; then
echo "Installed version of ${BINARY_NAME} is v${installed_version} which is already ${DESIRED_TAG:-latest}"
if [[ "${installed_version}" == "${TAG}" ]]; then
echo "Installed version of ${BINARY_NAME} is ${installed_version} which is already ${DESIRED_TAG:-latest}"
return 0
else
echo "New version of ${BINARY_NAME} is available: ${TAG}."
echo "Updating from ${BINARY_NAME} version v${installed_version} to ${TAG}"
echo "Updating from ${BINARY_NAME} version ${installed_version} to ${TAG}"
return 1
fi
else
Expand Down

0 comments on commit 7657110

Please sign in to comment.