Skip to content

armgit / mocha

Public Imported from GitHub
0

☕️ Classic, reliable, trusted test framework for Node.js and the browser

fix: use semver dot separator for beta pre-release versions (beta-X → beta.X) (#5764)

Copilot557473828570
diff --git a/.github/release-please/manifest.json b/.github/release-please/manifest.json
index 624f9772..7e5fff27 100644
--- a/.github/release-please/manifest.json
+++ b/.github/release-please/manifest.json
@@ -1 +1 @@
-{".":"12.0.0-beta-10"}
+{".":"12.0.0-beta.10"}
diff --git a/.github/workflows/mocha.yml b/.github/workflows/mocha.yml
index 3719d45b..35024594 100644
--- a/.github/workflows/mocha.yml
+++ b/.github/workflows/mocha.yml
@@ -4,11 +4,29 @@ on:
push:
branches:
- main
- paths-ignore: ["*.md", "docs/**", "docs-next/**", ".github/**", ".prettierignore", "AUTHORS", "LICENSE"]
+ paths-ignore:
+ [
+ "*.md",
+ "docs/**",
+ "docs-next/**",
+ ".github/**",
+ ".prettierignore",
+ "AUTHORS",
+ "LICENSE",
+ ]
pull_request:
branches:
- main
- paths-ignore: ["*.md", "docs/**", "docs-next/**", ".github/**", ".prettierignore", "AUTHORS", "LICENSE"]
+ paths-ignore:
+ [
+ "*.md",
+ "docs/**",
+ "docs-next/**",
+ ".github/**",
+ ".prettierignore",
+ "AUTHORS",
+ "LICENSE",
+ ]
types: [opened, synchronize, reopened, edited]
workflow_dispatch:
diff --git a/MAINTAINERS.md b/MAINTAINERS.md
index 7bb99b72..e5a9a006 100644
--- a/MAINTAINERS.md
+++ b/MAINTAINERS.md
@@ -421,12 +421,16 @@ For large releases, we recommend betas, then release candidates (RCs), then a fu
Betas are when most features are available, but more will likely be added before full release.
RCs are almost ready for release, but would benefit from user testing before a full release.
-To start a new major version beta, add `Release-As: 12.0.0-beta-1` to the additional details of your PR commit message.
+To start a new major version beta, add `Release-As: 12.0.0-beta.1` to the additional details of your PR commit message.
This must be part the last line of the commit message, not the PR description.
Release Please respects this property and will update accordingly.
You can also set Release Please to prelease mode to increment the beta number.
-To transition to an RC, add `Release-As: 12.0.0-rc-1` at the end of the PR commit message.
+> **Important:** Always use a dot (`.`) as the separator between the pre-release label and the number (e.g. `beta.1`, not `beta-1`).
+> The `semver` library (used by npm) treats dot-separated numeric identifiers numerically, so `beta.10 > beta.9`.
+> With a dash separator, `beta-10` is a single string identifier and sorts before `beta-9` alphabetically.
+
+To transition to an RC, add `Release-As: 12.0.0-rc.1` at the end of the PR commit message.
To transition from betas or RCs to a full release, just change Release Please back to `prerelease: false`.
diff --git a/package-lock.json b/package-lock.json
index 83c203d9..1cc2e1c3 100644
--- a/package-lock.json
+++ b/package-lock.json
@@ -1,12 +1,12 @@
{
"name": "mocha",
- "version": "12.0.0-beta-10",
+ "version": "12.0.0-beta.10",
"lockfileVersion": 3,
"requires": true,
"packages": {
"": {
"name": "mocha",
- "version": "12.0.0-beta-10",
+ "version": "12.0.0-beta.10",
"license": "MIT",
"dependencies": {
"browser-stdout": "^1.3.1",
diff --git a/package.json b/package.json
index 54e6bfde..8306c750 100644
--- a/package.json
+++ b/package.json
@@ -1,6 +1,6 @@
{
"name": "mocha",
- "version": "12.0.0-beta-10",
+ "version": "12.0.0-beta.10",
"type": "commonjs",
"description": "Classic, reliable, trusted test framework for Node.js and the browser",
"keywords": [