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
chore(ci): add a release-please configuration #630
Conversation
Current dependencies on/for this PR:
This comment was auto-generated by Graphite. |
0ae3275
to
9387093
Compare
Here's an example (not a monorepo): of a PR it would create: boneskull/midnight-smoker#238 And here's an example of what happens after you merge (with automatic publish to npm, which I manually configured): https://github.com/boneskull/midnight-smoker/actions/runs/5651165831/job/15308801239 Here's a GitHub Release it created and the associated update in the package's |
FWIW, for now, once you get over the configuration hump, release-please is pretty nice. It remains to be seen how well it works on a monorepo, but it was designed with that in mind. |
this is done |
9387093
to
d2425c1
Compare
d2425c1
to
4d7306e
Compare
This PR now targets the "fiddle with Lerna" PR, as it's built on that foundation. |
4d7306e
to
05ef261
Compare
60bd6bb
to
ab6f830
Compare
05ef261
to
560ac86
Compare
ab6f830
to
1118470
Compare
560ac86
to
94c86aa
Compare
1118470
to
6d551f7
Compare
94c86aa
to
34c0783
Compare
@@ -3,7 +3,10 @@ | |||
"changelogPreset": "conventional-changelog-conventionalcommits", | |||
"command": { | |||
"publish": { | |||
"message": "chore: publish" | |||
"message": "chore: publish", | |||
"fromPackage": true, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
does this mean e.g. for a lavamoat-core
core update
since 4 other pkgs depend on it
- ref: https://github.com/LavaMoat/LavaMoat/blob/main/RELEASE.md#release-dependency
- prev bumps: core/version 14.2.0 #610
we'll create 4 new separate-pull-requests
to update them?
or these will be included in the original PR?
ref: https://lerna.js.org/docs/features/version-and-publish#from-package
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@leotm I'm not sure I understand the context of asking this in the lerna config
release-please is configured to create separate pull requests for each public workspace (package). we are in control of how or when those get merged, and are also in control of how or when those get finally published. but they all must be published at once!
so when we merge a change to lavamoat-core
, a PR is created for that. once that PR is merged, then PRs will be created for each of the packages which depend on the new version of lavamoat-core
. it would be a mistake to merge and publish those before publishing the new version of lavamoat-core
since they will not exist in the registry. because lerna is configured to publish everything that needs publishing, we avoid this problem. so publishing in any other way besides this is just asking for trouble.
This may be why the default behavior of release-please is to not create separate pull requests, because it may become confusing. if it turns out we don't like separate PRs, I propose we simply...disable this behavior. 😄
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
some comments no blockers 👍
6d551f7
to
d1db251
Compare
39090de
to
739366e
Compare
This encodes the proper `lerna publish` flags within `lerna.json`. `release-please` will handle creating the GitHub release and updating the changelog, and we just want Lerna to publish what we have. These flags are essentially the same thing we have currently, sans the `--yes` flag.
739366e
to
da37069
Compare
This adds configuration for releasing with the release-please action.
The way it works, in a nutshell:
main
npm publish
must be run manually by a human