From f8279b2f8d9cf5094491b3317cb9ed74810c9a1b Mon Sep 17 00:00:00 2001 From: astridx Date: Tue, 17 Aug 2021 12:07:00 +0200 Subject: [PATCH 1/4] put docs together in doc folder --- RELEASE-PROCESS.md => docs/RELEASE-PROCESS.md | 0 docs/making-a-release.md | 4 ++-- 2 files changed, 2 insertions(+), 2 deletions(-) rename RELEASE-PROCESS.md => docs/RELEASE-PROCESS.md (100%) diff --git a/RELEASE-PROCESS.md b/docs/RELEASE-PROCESS.md similarity index 100% rename from RELEASE-PROCESS.md rename to docs/RELEASE-PROCESS.md diff --git a/docs/making-a-release.md b/docs/making-a-release.md index 1e92fc23eb..246a8c8ee1 100644 --- a/docs/making-a-release.md +++ b/docs/making-a-release.md @@ -6,7 +6,7 @@ Until we have CI going, anyone with the necessary permissions on npmjs should be 2. It will prompt you for a new version number, just increment the rc.X number for now 3. It will build a number of asset types, and test maplibre-gl 4. It will diff the tarball with the previous release of maplibre-gl on npm and ask you to confirm (makes it easy to spot build errors, etc), **note you may need to type y or n and press enter** at this phase to continue 🤷‍♂️ -5. Publish the new version to npm +5. Publish the new version to npm. See [RELEASE-PROCESS.md](./RELEASE-PROCESS.md). 6. Update your package.json and git tags on the host machine even though the thing executes in docker 🧙🏿‍♂️. **You should commit the new package.json and push**. 7. Print the URL to the new release @@ -23,5 +23,5 @@ is following to make the `v1.13.0-rc` releases from his local machine: - `yarn test` (note: this appears to sporadically sometimes fail with a JSON parse error of `babylon/package.json`, not sure why its not deterministic in this respect) - `yarn prepublishOnly` (this will be run automatically by `yarn publish` too, but it can help to debug this relatively-complex step separately until it works on your machine reliably, and you're happy with the result) - Update `package.json` to increment the `-rc.____` version, note that we don't use yarns auto-increment feature in `yarn publish` presently, because it struggles with patch release incrementing, and the `-rc.` approach is important to a smooth first `v1.13.0` -- `npm publish`, note that we are using npm publish here, not yarn, I have yet to get `yarn publish` working +- Publish the new version to npm. See [RELEASE-PROCESS.md](./RELEASE-PROCESS.md). - Check `https://www.npmjs.com/package/maplibre-gl` for the new version, and ideally test the new version until we build more confidence from repitition, and automate this procedure (I use a simple jsfiddle pointing at an unpkg url for quick "does it load" final validation) From 8efffb784c85b07597b5a8abef3110a30d59de66 Mon Sep 17 00:00:00 2001 From: astridx Date: Tue, 17 Aug 2021 19:40:35 +0200 Subject: [PATCH 2/4] https://github.com/maplibre/maplibre-gl-js/pull/246#issuecomment-900200494 --- docs/making-a-release.md | 27 --------------------------- 1 file changed, 27 deletions(-) delete mode 100644 docs/making-a-release.md diff --git a/docs/making-a-release.md b/docs/making-a-release.md deleted file mode 100644 index 246a8c8ee1..0000000000 --- a/docs/making-a-release.md +++ /dev/null @@ -1,27 +0,0 @@ -# Making a release with docker (recommended) - -Until we have CI going, anyone with the necessary permissions on npmjs should be able to make a release, using the simple repeatable docker-based `./build/publish-release.sh` script. - -1. Run `./build/publish-release.sh` -2. It will prompt you for a new version number, just increment the rc.X number for now -3. It will build a number of asset types, and test maplibre-gl -4. It will diff the tarball with the previous release of maplibre-gl on npm and ask you to confirm (makes it easy to spot build errors, etc), **note you may need to type y or n and press enter** at this phase to continue 🤷‍♂️ -5. Publish the new version to npm. See [RELEASE-PROCESS.md](./RELEASE-PROCESS.md). -6. Update your package.json and git tags on the host machine even though the thing executes in docker 🧙🏿‍♂️. **You should commit the new package.json and push**. -7. Print the URL to the new release - -### Without docker (not recommended) - -Until we draft more formal docs, get CI going, and develop our own -release process suited to our needs, here are the steps Seth -is following to make the `v1.13.0-rc` releases from his local machine: - -- verify that `yarn --version` >= 1.22 -- `git clone https://github.com/maplibre/maplibre-gl-js.git` -- `cd maplibre-gl-js` -- `yarn install` -- `yarn test` (note: this appears to sporadically sometimes fail with a JSON parse error of `babylon/package.json`, not sure why its not deterministic in this respect) -- `yarn prepublishOnly` (this will be run automatically by `yarn publish` too, but it can help to debug this relatively-complex step separately until it works on your machine reliably, and you're happy with the result) -- Update `package.json` to increment the `-rc.____` version, note that we don't use yarns auto-increment feature in `yarn publish` presently, because it struggles with patch release incrementing, and the `-rc.` approach is important to a smooth first `v1.13.0` -- Publish the new version to npm. See [RELEASE-PROCESS.md](./RELEASE-PROCESS.md). -- Check `https://www.npmjs.com/package/maplibre-gl` for the new version, and ideally test the new version until we build more confidence from repitition, and automate this procedure (I use a simple jsfiddle pointing at an unpkg url for quick "does it load" final validation) From eef79c7aec18d3393b48d0fd7ac39f5cde839067 Mon Sep 17 00:00:00 2001 From: astridx Date: Tue, 17 Aug 2021 19:42:08 +0200 Subject: [PATCH 3/4] https://github.com/maplibre/maplibre-gl-js/commit/b425b8e2caff4f3b7d894755fa0f7e13e4650ed9#r55032517 --- package.json | 1 - 1 file changed, 1 deletion(-) diff --git a/package.json b/package.json index 2e39031b5c..d87f8e6031 100644 --- a/package.json +++ b/package.json @@ -148,7 +148,6 @@ "start-bench": "run-p watch-benchmarks start-server", "start-release": "run-s build-prod-min build-css print-release-url start-server", "diff-tarball": "cross-env build/run-node build/diff-tarball", - "prepare-publish": "git clean -fdx & npm install", "lint": "eslint --cache --ignore-path .gitignore src test bench build debug/*.html", "lint-docs": "documentation lint src/index.js", "lint-css": "stylelint 'src/css/maplibre-gl.css'", From 3b9815058dd7e46838ea79fc393c92f10f821329 Mon Sep 17 00:00:00 2001 From: astridx Date: Wed, 18 Aug 2021 09:48:57 +0200 Subject: [PATCH 4/4] forgotton --- package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/package.json b/package.json index d87f8e6031..ff28c1d17d 100644 --- a/package.json +++ b/package.json @@ -164,7 +164,7 @@ "test-expressions": "cross-env build/run-node test/expression.test.js", "test-flow": "cross-env build/run-node build/generate-flow-typed-style-spec && flow .", "test-cov": "nyc --require=@mapbox/flow-remove-types/register --reporter=text-summary --reporter=lcov --cache run-s test-unit test-expressions test-query test-render", - "prepublishOnly": "run-s prepare-publish build-flow-types build-dev build-prod-min build-prod build-csp build-css build-style-spec test-build diff-tarball", + "prepublishOnly": "run-s build-flow-types build-dev build-prod-min build-prod build-csp build-css build-style-spec test-build diff-tarball", "print-release-url": "node build/print-release-url.js", "codegen": "cross-env build/run-node build/generate-style-code.js && build/run-node build/generate-struct-arrays.js" },