|
| 1 | +# Creating a release |
| 2 | + |
| 3 | +Only collaborators in npm for **node-api-headers** can create releases. If you |
| 4 | +want to be able to do releases ask one of the existing collaborators to add |
| 5 | +you. If necessary you can ask the build Working Group who manages the Node.js |
| 6 | +npm user to add you if there are no other active collaborators. |
| 7 | + |
| 8 | +## Prerequisites |
| 9 | + |
| 10 | +Before to start creating a new release check if you have installed the following |
| 11 | +tools: |
| 12 | + |
| 13 | +* [Changelog maker](https://www.npmjs.com/package/changelog-maker) |
| 14 | + |
| 15 | +If not please follow the instruction reported in the tool's documentation to |
| 16 | +install it. |
| 17 | + |
| 18 | +## Publish new release |
| 19 | + |
| 20 | +These are the steps to follow to create a new release: |
| 21 | + |
| 22 | +* Open an issue in the **node-api-headers** repo documenting the intent to |
| 23 | +create a new release. Give people some time to comment or suggest PRs that |
| 24 | +should land first. |
| 25 | + |
| 26 | +* Update the version in **package.json** appropriately. |
| 27 | + |
| 28 | +* Update the [README.md][] to show the latest stable version of Node-API. |
| 29 | + |
| 30 | +* Generate the changelog for the new version using **changelog maker** tool. |
| 31 | +From the root folder of the repo launch the following command: |
| 32 | + |
| 33 | +```bash |
| 34 | +> changelog-maker --format=markdown |
| 35 | +``` |
| 36 | + |
| 37 | +* Use the output generated by **changelog maker** to update the |
| 38 | +[CHANGELOG.md][] following the style used in publishing the previous release. |
| 39 | + |
| 40 | +* Add any new contributors to the "contributors" section in the |
| 41 | +**package.json**. |
| 42 | + |
| 43 | +* Do a clean checkout of `node-api-headers`. |
| 44 | + |
| 45 | +* Login and then run `npm publish`. |
| 46 | + |
| 47 | +* Create a release in Github (look at existing releases for an example). |
| 48 | + |
| 49 | +* Validate that you can run `npm install node-api-headers` successfully |
| 50 | +and that the correct version is installed. |
| 51 | + |
| 52 | +* Comment on the issue opened in the first step that the release has been created |
| 53 | +and close the issue. |
| 54 | + |
| 55 | +* Tweet that the release has been created. |
| 56 | + |
| 57 | +[README.md]: ./README.md |
| 58 | +[CHANGELOG.md]: ./CHANGELOG.md |
0 commit comments