Skip to content

fix: use changeset publish to enable GitHub release creation#8

Merged
eli0shin merged 2 commits intomainfrom
fix-release-creation
Dec 26, 2025
Merged

fix: use changeset publish to enable GitHub release creation#8
eli0shin merged 2 commits intomainfrom
fix-release-creation

Conversation

@eli0shin
Copy link
Owner

Summary

  • Replace custom npm publish script with changeset publish command
  • Enable automatic GitHub release creation through changesets/action
  • Remove scripts/release.sh as it's no longer needed

Problem

The custom release script (scripts/release.sh) used npm publish directly, which doesn't output the "New tag:" format that changesets/action expects. The changesets/action parses this specific output to detect newly published packages and automatically create GitHub releases. Without this output format, GitHub releases were not being created even though packages were successfully published to npm.

Solution

Switched from the custom bash scripts/release.sh to using bunx changeset publish in the version workflow. The changeset publish command:

  • Handles the version check internally (won't re-publish existing versions)
  • Outputs in the format that changesets/action expects
  • Enables automatic GitHub release creation when packages are published

This simplifies the workflow by removing the custom script and leveraging changesets' built-in publishing mechanism that integrates properly with the changesets/action's release creation feature.

Changes

  • Updated .github/workflows/version.yml to use bunx changeset publish instead of custom script
  • Removed scripts/release.sh since version checking is handled by changeset publish
  • Added changeset documenting the fix

🤖 Generated with Claude Code

eli0shin and others added 2 commits December 26, 2025 02:05
The custom release script used npm publish which doesn't output "New tag:"
that changesets/action parses to detect published packages and create GitHub
releases. Replaced with bunx changeset publish which provides the expected
output format.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
@changeset-bot
Copy link

changeset-bot bot commented Dec 26, 2025

🦋 Changeset detected

Latest commit: d584448

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 1 package
Name Type
barkql Patch

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

@eli0shin eli0shin marked this pull request as ready for review December 26, 2025 07:09
Copilot AI review requested due to automatic review settings December 26, 2025 07:09
@eli0shin eli0shin merged commit 8817ef3 into main Dec 26, 2025
2 checks passed
@eli0shin eli0shin deleted the fix-release-creation branch December 26, 2025 07:09
@github-actions github-actions bot mentioned this pull request Dec 26, 2025
Copy link

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR modernizes the package publishing workflow by replacing a custom npm publish script with the standard changeset publish command. This change enables automatic GitHub release creation, which was previously failing because the custom script didn't output the format expected by changesets/action.

Key Changes:

  • Switch from custom bash scripts/release.sh to bunx changeset publish in the version workflow
  • Remove the now-redundant scripts/release.sh file
  • Add a changeset documenting the fix

Reviewed changes

Copilot reviewed 3 out of 3 changed files in this pull request and generated no comments.

File Description
.github/workflows/version.yml Updated publish command to use bunx changeset publish instead of custom script
scripts/release.sh Removed custom release script as version checking is now handled by changeset publish
.changeset/swift-doors-glow.md Added changeset documentation for this fix
Comments suppressed due to low confidence (1)

.github/workflows/version.yml:41

  • The workflow is missing the NPM authentication token required for publishing. When using changeset publish, you need to provide either NODE_AUTH_TOKEN or NPM_TOKEN in the environment variables. Since actions/setup-node@v4 is configured with registry-url, add NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }} to the env section alongside GITHUB_TOKEN.
          publish: bunx changeset publish
          title: 'chore: version packages'
          createGithubReleases: true
        env:
          GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

eli0shin pushed a commit that referenced this pull request Dec 26, 2025
This PR was opened by the [Changesets
release](https://github.com/changesets/action) GitHub action. When
you're ready to do a release, you can merge this and the packages will
be published to npm automatically. If you're not ready to do a release
yet, that's fine, whenever you add more changesets to main, this PR will
be updated.


# Releases
## barkql@0.1.3

### Patch Changes

- [#8](#8)
[`8817ef3`](8817ef3)
Thanks [@eli0shin](https://github.com/eli0shin)! - Fix GitHub releases
not being created by using `changeset publish` instead of a custom npm
publish script, which provides the expected "New tag:" output format
that changesets/action parses.

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant