diff options
author | John Firebaugh <john.firebaugh@gmail.com> | 2018-07-31 08:52:33 -0700 |
---|---|---|
committer | GitHub <noreply@github.com> | 2018-07-31 08:52:33 -0700 |
commit | 2c5bebbdd8a5fc16719145b06e5812851fdb8751 (patch) | |
tree | eb2be22448e56ebf4f1566bb18c65cfd134e9aea /platform | |
parent | 9a1bb1ad14e18433d4cc8e805af57a6014275561 (diff) | |
download | qtlocation-mapboxgl-2c5bebbdd8a5fc16719145b06e5812851fdb8751.tar.gz |
[node] Update documentation for publishing process (#12500)
* Update node publishing process
* publish instruction separated into steps
Diffstat (limited to 'platform')
-rw-r--r-- | platform/node/DEVELOPING.md | 16 |
1 files changed, 11 insertions, 5 deletions
diff --git a/platform/node/DEVELOPING.md b/platform/node/DEVELOPING.md index 215b06c7bf..245847b421 100644 --- a/platform/node/DEVELOPING.md +++ b/platform/node/DEVELOPING.md @@ -4,7 +4,7 @@ This document explains how to build the [Node.js](https://nodejs.org/) bindings ## Building -To develop these bindings, you’ll need to build them from source. Building requires the prerequisites listed in either +To develop these bindings, you’ll need to build them from source. Building requires the prerequisites listed in either the [macOS](../macos/INSTALL.md#requirements) or [Linux](../linux/README.md#prerequisites) install documentation, depending on the target platform. @@ -36,13 +36,19 @@ To clean up your pull request and prepare it for merging, update your local `mas ## Publishing -After your pull request has been merged (and you've fetched the latest `master` if merged from the GitHub UI), make a new commit in the `master` branch that updates the version number in [`package.json`](../../package.json#L3) and adds an entry in [`platform/node/CHANGELOG.md`](CHANGELOG.md) describing the changes in your release. +To publish a new version of the `@mapbox/mapbox-gl-native` package: +- [ ] make a commit in the branch being published including: + - [ ] updated version number in [`package.json`](../../package.json#L3) + - [ ] an entry in [`platform/node/CHANGELOG.md`](CHANGELOG.md) describing the changes in your release +- [ ] run `git tag node-v{VERSION}` where `{VERSION}` matches the version in `package.json`, e.g. `git tag node-v3.3.2` +- [ ] run `git push && git push --gs` -Tag this commit with `git tag node-v{VERSION}` where `{VERSION}` matches the version in `package.json`, like `git tag node-v3.3.2`, then run `git push && git push --gs`. Travis CI integration runs on tag publishes and will check if the `$TAG` env var [matches the version listed in `package.json`](https://github.com/mapbox/mapbox-gl-native/blob/94a58691e24cd0760f9a3c2ac1a9322aa7854367/.travis.yml#L62-L64), and if so, will run with `BUILDTYPE=Release` and [publish a binary with `node-pre-gyp`](https://github.com/mapbox/mapbox-gl-native/blob/94a58691e24cd0760f9a3c2ac1a9322aa7854367/platform/node/scripts/after_script.sh#L9-L15). +The CI builds for tag pushes will check if the tag matches the version listed in `package.json`, and if so, will run with `BUILDTYPE=Release` and publish a binary with `node-pre-gyp`. -This autopublish on git tag workflow [broke for macOS binaries when we switched over to Bitrise](https://github.com/mapbox/mapbox-gl-native/issues/4854), so the temporary workaround has been to manually publish macOS binaries after pushing the new tag. Make sure the `mason` submodule is up to date with `git submodule update --init` then run `make distclean && BUILDTYPE=Release npm install --build-from-source && ./node_modules/.bin/node-pre-gyp package publish info`. +Once binaries have been published for Linux and macOS (which can be verified with `./node_modules/.bin/node-pre-gyp info`), you can run a quick final check to ensure they're being fetched properly by simply running `rm -rf lib && npm install`. -Once binaries have been published for Linux and macOS (which can be verified with `./node_modules/.bin/node-pre-gyp info`), you can run a quick final check to ensure they're being fetched properly by simply running `rm -rf lib && npm install`. If everything looks good, run `npm publish`! +If everything looks good: +- [ ] run `mbx npm publish` ### Preleases |