diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index 36785cd59f..0e9e8f1d5e 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -389,6 +389,8 @@ To build a new version and release it on NPM, follow these steps: npm publish rescript-std-.tgz [--tag next] ``` 1. Tag the commit with the version number (e.g., "10.0.0", or "10.0.0-beta.1") and push the tag. +1. Create a release entry for that tag on the [Github Releases page](https://github.com/rescript-lang/rescript-compiler/releases), copying the changes from `Changes.md`. +1. Coordinate any forum/blog posts with [@ryyppy](https://github.com/ryyppy). ## Contribution Licensing diff --git a/package-lock.json b/package-lock.json index a7c21ee6e9..94fbcd6283 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1,12 +1,12 @@ { "name": "rescript", - "version": "10.0.0-beta.1", + "version": "10.0.0-beta.2", "lockfileVersion": 2, "requires": true, "packages": { "": { "name": "rescript", - "version": "10.0.0-beta.1", + "version": "10.0.0-beta.2", "hasInstallScript": true, "license": "SEE LICENSE IN LICENSE", "bin": { diff --git a/package.json b/package.json index cd353dfa76..4a60583532 100644 --- a/package.json +++ b/package.json @@ -1,5 +1,6 @@ { "name": "rescript", + "version": "10.0.0-beta.2", "devDependencies": { "mocha": "^7.2.0", "nyc": "^15.0.0", @@ -22,7 +23,6 @@ "test-env-compiler": "RESCRIPT_FORCE_REBUILD=1 node scripts/install.js -use-env-compiler", "coverage": "nyc --timeout=3000 --reporter=html mocha jscomp/test/*test.js && open ./coverage/index.html" }, - "version": "10.0.0-beta.2", "description": "ReScript toolchain", "files": [ "Changes.md", diff --git a/scripts/setVersion.js b/scripts/setVersion.js index f86f8f7646..b3f24fb743 100644 --- a/scripts/setVersion.js +++ b/scripts/setVersion.js @@ -3,7 +3,7 @@ * This file is used only in dev time, feel free to use es6 */ const fs = require("fs"); -const path = require("path"); +const { execSync } = require("child_process"); const packageSpec = JSON.parse(fs.readFileSync("./package.json", "utf8")); const { version, name } = packageSpec; @@ -48,3 +48,6 @@ let package_name = ref "${name}" `, "utf8" ); + +// For some reason, the version number is also in npm's package-lock.json. This updates it. +execSync("npm i --ignore-scripts", { stdio: "inherit" });