diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 7d92c78..e6b5437 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -32,6 +32,15 @@ jobs: env: NODE_AUTH_TOKEN: ${{ secrets.NPM_PUBLISH_KEY }} + - name: Check if version was bumped + run: | + LAST_TAG=$(git describe --tags --abbrev=0) + HEAD_TAG=$(git describe --tags) + if [ "$LAST_TAG" == "$HEAD_TAG" ]; then + echo "No new version detected, skipping push and publish." + exit 0 + fi + - name: Push version changes run: | git push --follow-tags origin main