-
-
Notifications
You must be signed in to change notification settings - Fork 54
ci: semantic releases #335
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
Conversation
2ce5b21 to
69a3c8c
Compare
Thanks a lot for this @dhensby
I have nom publishing access but I'd like to limit this only to the master branch so new releases are definitely reviewed beforehand by at least two of us. What do you think?
By default the release process won't work unless it's in a list of the default branches (master, next, and then N.x for changes to other versions). We can limit this to just master either in the release config or in the GH workflow (or both).
Ok then we can leverage npm tags so everything on next is also tagged @next (like alpha beta release candidate) and not auto installed by users while releases on master can be tagged @latest so they are installable without explicit version pinning
Yep - that's how it works "out of the box" 👍
@dhensby I just merged some dependabot dev-dependencies. Would these kinds of merges be ignored by your current PR?
I just merged some dependabot dev-dependencies. Would these kinds of merges be ignored by your current PR?
No; they are flagged as build: or sometimes chore(deps): commits that don't trigger releases. Also, if you use @dependabot merge command, the CI is run in reduced-privilege mode which means that the runs don't have access to the secrets and so they can't be used to perform releases.
In regard to dependencies, our version constraints should be permissive enough that any upstream consumer can be responsible for upgrading any packages that have vulnerabilities or bugs; if we start to depend on new major versions of dependencies that form part of our outward facing APIs (I don't think they do), then we should probably manually update them with at least minor and maybe major change releases.
69a3c8c to
cac8b96
Compare
Uh oh!
There was an error while loading. Please reload this page.
Summary
This change adds semantic releases to the release pipeline. Commits are automatically analysed when they are merged into
masterand depending on the commit message (fix,feat), a new release will be authored (tagged in git, pushed to GH releases and NPM); this includes updating the release version inpackage.jsonand updating theCHANGELOG.MD.Other added benefits are NPM attestation of releases, no human dependencies on releases, fixes are released as soon as they are merged.
Contributors will now have to ensure their commits conform to the conventional commits standard
Outstanding actions:
NPM_TOKEN.GITHUB_TOKEN.The GH token needs the following access:
Linked issue(s)
See discussion #310
Involved parts of the project
Releases / automation.
Added tests?
N/A
OAuth2 standard
N/A
Reproduction
N/A