From 562b14ab6128b9ccbe9975eed4db8ea1551d70d5 Mon Sep 17 00:00:00 2001 From: arkon Date: Sat, 28 Feb 2026 15:05:12 +0100 Subject: [PATCH] fix: rename GitHub release tags from aicodeman to codeman npm package stays as aicodeman (name taken), but GitHub releases now show as codeman@x.y.z via a post-publish retag step. Co-Authored-By: Claude Opus 4.6 --- .github/workflows/release.yml | 22 ++++++++++++++++++++++ 1 file changed, 22 insertions(+) diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 037936fa..bed16d07 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -42,3 +42,25 @@ jobs: env: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }} + + - name: Rename release tag to codeman + if: steps.changesets.outputs.published == 'true' + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + run: | + VERSION=$(node -p "require('./package.json').version") + OLD_TAG="aicodeman@${VERSION}" + NEW_TAG="codeman@${VERSION}" + + # Retag + git tag "$NEW_TAG" "$OLD_TAG" 2>/dev/null || true + git tag -d "$OLD_TAG" 2>/dev/null || true + git push origin "$NEW_TAG" ":refs/tags/$OLD_TAG" 2>/dev/null || true + + # Update the GitHub release to use the new tag + RELEASE_ID=$(gh release view "$OLD_TAG" --json id -q .id 2>/dev/null || true) + if [ -n "$RELEASE_ID" ]; then + gh api -X PATCH "repos/${{ github.repository }}/releases/${RELEASE_ID}" \ + -f tag_name="$NEW_TAG" \ + -f name="$NEW_TAG" + fi