-
-
Notifications
You must be signed in to change notification settings - Fork 334
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
Update node release based on maplibre-js release workflow #1986
Conversation
I had changed this to true a while back, but this should be false. we do not have the gyp files required for this build to work
…ngl-2 branch (maplibre#1941) Co-authored-by: mwilsnd <[email protected]> Co-authored-by: Bart Louwers <[email protected]>
Any suggestions on how to fix the 'pre-commit.ci' |
@acalcutt You can run
locally or install all pre-commit hooks with
(after installing pre-commit with pip or another package manager). I left some suggestions that will solve the issue I think. |
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.
Looks great!
I changed this a little bit so instead of checking if the current version matched the latest version published, it just checks if the version is published. In testing I realized If I published a newer version on a different branch (like main), it would break publishing of lower version releases (like I want to do with the opengl-2 branch). Just checking if it is published will allow simultaneous releases and allow it to only publish when needed still. |
i still haven't figured out that last pre-commit.ci error, it still doesn't like line 27 but it seems like most of it is in quotes now... |
@louwers I was wondering what you think about this. In a test branch I added code that adds the node changelog to these releases. This is also based on the maplibre-js release workflow. It takes the version change information from 'platform/node/CHANGELOG.md' and Updates the release with the text for the version posted. This needs this script i modified from maplibre-js, like this one I also had to fix the indentation #'s in 'platform/node/CHANGELOG.md' to match what maplibre-js used Do you think these changes are an improvement? should I merge them in here? |
Sure, let's try it out. Maybe in a different PR? Can you put the script in Can you error when no release notes are found? |
@acalcutt I am using this awk one-liner now for iOS: maplibre-native/.github/workflows/ios-ci.yml Line 220 in fe728eb
|
I am going to close this in favor of #1995 . I have moved that PR to use awk like recommended |
This PR updates the node release workflow so it no longer increments the version on it's own. This should allow it to work with the approval requirements on this repo. I've made this work more like the maplibre-js workflow at https://github.com/maplibre/maplibre-gl-js/blob/b7b86c1018842a139d4ced21a071ca4a3d9f24b5/.github/workflows/release.yml .
To increment the version now, someone would make a PR that changes the version in package.json located in the root directory (which is used for node). Once that change is made, the workflow automatically checks against the published version on npm. If the version has changed, the binaries get built and published to github using NODE_PRE_GYP_GUTHUB, then the release is published to npm
I've also cherry picked some workflow fixes I made in the opengl-2 branch.
I was also thinking about versioning. Maybe in the 'opengl-2' branch we can continue a 5.x release , but in main we can start with '6.0.0-pre.0' (once we get something together for a metal pre-release)
Testing
I have created a test release (minus macos support) at
https://github.com/WifiDB/maplibre-native/actions/runs/7368227110/job/20052326170
https://www.npmjs.com/package/@acalcutt/maplibre-gl-native-test/v/5.2.1-pre.9
https://github.com/WifiDB/maplibre-native/releases/tag/node-v5.2.1-pre.9
Wishlist
A way to update release changelog based on https://github.com/maplibre/maplibre-native/blob/main/platform/node/CHANGELOG.md
Notes
After this is approved I plan to cherry pick these changes over to 'opengl-2' so I could also make a updated release with macos support there, so a squash and merge may be easier if this is merged.