diff --git a/script/release/next-docker-tag.sh b/script/release/next-docker-tag.sh index 082d58c..6a307f1 100755 --- a/script/release/next-docker-tag.sh +++ b/script/release/next-docker-tag.sh @@ -2,7 +2,7 @@ set -e source script/functions gem_version=$(gem_version_from_gemfile_lock) DOCKER_IMAGE="pactfoundation/pact-broker" -existing_tags=$(wget -q https://registry.hub.docker.com/v1/repositories/${DOCKER_IMAGE}/tags -O - | jq -r .[].name ) +existing_tags=$(wget -q https://registry.hub.docker.com/v1/repositories/${DOCKER_IMAGE}/tags -O - | jq -r .[].name | sed 's/-[0-9]$/.1/g') existing_release_numbers_for_current_gem_version=$(echo "$existing_tags" | grep "${gem_version}\." | sed 's/'${gem_version}'\.//g' | grep -E "^[0-9]+$" | cat) if [ -n "${existing_release_numbers_for_current_gem_version}" ]; then