Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ci: create an action to release to npm automatically when a new git tag is created #14

Merged
merged 5 commits into from
Oct 12, 2023

Conversation

mhmd-azeez
Copy link
Collaborator

Fixes #12

For Deno, we just need to submit the repo here: https://deno.com/add_module, I don't have the right permissions to do it

Note: the git tags must no longer have the v prefix, let me know if this is a deal breaker. Example: 1.0.0-rc2

@mhmd-azeez
Copy link
Collaborator Author

@wikiwong we need a NPM_TOKEN in the secrets for the CI

@wikiwong
Copy link
Contributor

@mhmd-azeez I've added the NPM_TOKEN secret to this repository

Copy link
Contributor

@wikiwong wikiwong left a comment

Choose a reason for hiding this comment

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

This PR looks good to me. The only thing I will caveat this with is that we may not always be publishing to NPM immediately once we tag for release. @chrisdickinson outlined a similar process we may want to use here: https://github.com/extism/python-sdk#release-workflow

I think this is ok for now so approving, but @chrisdickinson feel free to veto if you think we should wait

Copy link
Contributor

@chrisdickinson chrisdickinson left a comment

Choose a reason for hiding this comment

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

Ideally I'd like to follow the tag -> draft release, publish release -> publish to package managers flow that @wikiwong mentioned but I don't think it's a blocker here – I'd be happy to take a look at that in a subsequent PR. (Deno's webhooks make following this flow a little tricky since they assume that "tag publish" == "release".)

I did add some suggestions aimed at letting us use the same vX.X.X tagging scheme as other repos, though!

.github/workflows/release.yml Outdated Show resolved Hide resolved
.github/workflows/release.yml Outdated Show resolved Hide resolved
mhmd-azeez and others added 2 commits October 11, 2023 12:31
Co-authored-by: Chris Dickinson <chris@neversaw.us>
Copy link
Contributor

@chrisdickinson chrisdickinson left a comment

Choose a reason for hiding this comment

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

LGTM! I think we can land this and then iterate on the release flow in a separate PR.

@mhmd-azeez mhmd-azeez merged commit 9cef920 into main Oct 12, 2023
@mhmd-azeez mhmd-azeez deleted the ci/npm-publish branch October 12, 2023 10:01
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.

Continuous Delivery
3 participants