diff --git a/scripts/release.sh b/scripts/release.sh index aaa1e612c43..70e455e3ad8 100755 --- a/scripts/release.sh +++ b/scripts/release.sh @@ -254,7 +254,7 @@ main() { # Upload artifacts. if [ "${DRY_RUN}" == "true" ] || [ "${NO_UPLOAD}" == 1 ]; then - log_callout "Skipping artifact upload to gs://etcd. --no-upload flat is set." + log_callout "Skipping artifact upload to gs://etcd. --no-upload flag is set." else read -p "Upload etcd ${RELEASE_VERSION} release artifacts to gs://etcd [y/N]? " -r confirm [[ "${confirm,,}" == "y" ]] || exit 1 @@ -266,7 +266,7 @@ main() { # Push images. if [ "${DRY_RUN}" == "true" ] || [ "${NO_DOCKER_PUSH}" == 1 ]; then - log_callout "Skipping docker push. --no-docker-push flat is set." + log_callout "Skipping docker push. --no-docker-push flag is set." else read -p "Publish etcd ${RELEASE_VERSION} docker images to quay.io [y/N]? " -r confirm [[ "${confirm,,}" == "y" ]] || exit 1 @@ -364,7 +364,8 @@ main() { release_notes_temp_file=$(mktemp) local release_version=${RELEASE_VERSION#v} # Remove the v prefix from the release version (i.e., v3.6.1 -> 3.6.1) - local release_version_major_minor=${release_version%.*} # Remove the patch from the version (i.e., 3.6) + local release_version_major_minor + release_version_major_minor=$(echo "${release_version}" | cut -d. -f1-2) # Remove the patch from the version (i.e., 3.6) local release_version_major=${release_version_major_minor%.*} # Extract the major (i.e., 3) local release_version_minor=${release_version_major_minor/*./} # Extract the minor (i.e., 6)