From 63aa7376cc8e6e790baa074530d1c901a6e14d65 Mon Sep 17 00:00:00 2001 From: Micheal Wilkinson Date: Fri, 20 Mar 2026 21:29:26 +0000 Subject: [PATCH] fix: fail prepare when release tag already exists Prevent silent successful runs that skip tag creation. If the resolved release tag already exists locally or remotely, fail with guidance so users know why tag-triggered do-release will not run. --- prepare/action.yml | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/prepare/action.yml b/prepare/action.yml index 787c4bf..2362f2b 100644 --- a/prepare/action.yml +++ b/prepare/action.yml @@ -209,8 +209,9 @@ runs: git remote set-url origin "$authed_remote" if git rev-parse "$RELEASE_TAG" >/dev/null 2>&1 || git ls-remote --exit-code --tags origin "refs/tags/${RELEASE_TAG}" >/dev/null 2>&1; then - echo "Tag ${RELEASE_TAG} already exists; skipping commit/tag/push." - exit 0 + echo "Tag ${RELEASE_TAG} already exists; no new tag can be pushed, so tag-triggered release publication will not run." >&2 + echo "Choose a new version (or update changelog content so recommendation advances) and run Prepare Release again." >&2 + exit 1 fi for f in $GIT_ADD_FILES; do