Skip to content

Add GitHub publish workflow with trusted publishing#294

Merged
ajeetdsouza merged 15 commits intomainfrom
ajeet/npm
May 6, 2026
Merged

Add GitHub publish workflow with trusted publishing#294
ajeetdsouza merged 15 commits intomainfrom
ajeet/npm

Conversation

@ajeetdsouza
Copy link
Copy Markdown
Contributor

@ajeetdsouza ajeetdsouza commented Apr 30, 2026

Adding a GitHub Actions workflow to publish to npm. This uses trusted publishing to attach provenance attestations to packages, allowing users to verify their authenticity.

@ajeetdsouza ajeetdsouza requested a review from timostamm May 4, 2026 17:33
@ajeetdsouza ajeetdsouza marked this pull request as ready for review May 4, 2026 17:43
This replaces the npm "release" script with discrete workflow steps in publish.yaml.

The workflow calling npm, npm calling a node script, and the node script calling npm again seemed a bit much. This peels off one layer of the onion. This change also allows us to reuse scripts/gh-diffcheck.js instead of reimplementing the same check in release.js.
Comment thread scripts/publish.js
Comment thread scripts/publish.js
Comment thread scripts/publish.js
Comment thread .github/workflows/publish.yaml Outdated
Copy link
Copy Markdown
Member

@timostamm timostamm left a comment

Choose a reason for hiding this comment

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

This looks neat to me. Just a couple of nits, see below.

Can you update the PR title and add a description? PRs are linked in the release notes - they are our changelog. So a self-explanatory title and a description with details is generally useful for our users. The key change we're making here is to adopt trusted publishing, which is a significant security enhancement.

Comment thread .github/workflows/publish.yaml Outdated
Comment thread scripts/publish.js
@ajeetdsouza ajeetdsouza changed the title Add workfow to publish to npm Add GitHub publish workflow with trusted publishing May 6, 2026
This reverts commit d30b4c3.
Copy link
Copy Markdown
Member

@timostamm timostamm left a comment

Choose a reason for hiding this comment

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

LGTM!

@ajeetdsouza ajeetdsouza merged commit 4dca7ac into main May 6, 2026
11 checks passed
@ajeetdsouza ajeetdsouza deleted the ajeet/npm branch May 6, 2026 15:14
@ajeetdsouza ajeetdsouza mentioned this pull request May 6, 2026
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.

2 participants