Commit 5f242ebb032 for nodejs

commit 5f242ebb032e2b3c95258811e7fa27252bb28d10
Author: Rafael Gonzaga <rafael.nunu@hotmail.com>
Date:   Thu Oct 29 10:20:58 2026 -0300

    doc: note linear history rule on branch-off

    Pushing new `vN.x` and `vN.x-staging` branches to the repository is
    rejected by the "Require linear history" ruleset, because branch
    creation evaluates the whole history and `main` still contains merge
    commits from 2015. Document that a repository admin must disable the
    rule, push the branches, and enable it again, as done for v26.x and
    v27.x.

    Refs: https://github.com/nodejs/Release/issues/1187
    Signed-off-by: RafaelGSS <rafael.nunu@hotmail.com>
    PR-URL: https://github.com/nodejs/node/pull/67057
    Reviewed-By: Filip Skokan <panva.ip@gmail.com>
    Reviewed-By: Richard Lau <richard.lau@ibm.com>
    Reviewed-By: Ulises Gascón <ulisesgascongonzalez@gmail.com>
    Reviewed-By: Chengzhong Wu <legendecas@gmail.com>

diff --git a/doc/contributing/releases.md b/doc/contributing/releases.md
index bb48cb17b7b..f10407720f3 100644
--- a/doc/contributing/releases.md
+++ b/doc/contributing/releases.md
@@ -1420,6 +1420,17 @@ created as forks of the `main` branch. Alpha releases should be released picking
 up commits from `main`. Target the first alpha release to be released the same
 day as the previous release line is graduated to LTS status.

+Pushing the new branches is rejected by the [Require linear history][]
+repository rule, because creating a branch evaluates its whole history and
+`main` contains merge commits from 2015. A repository admin must disable the
+rule, push the branches, and enable it again:
+
+```bash
+gh api -X PUT repos/nodejs/node/rulesets/714811 -f enforcement=disabled
+git push upstream main:refs/heads/vN.x main:refs/heads/vN.x-staging
+gh api -X PUT repos/nodejs/node/rulesets/714811 -f enforcement=active
+```
+
 If a `SEMVER-MAJOR` pull request lands on the default branch within one month
 prior to the major release date, it must not be included on the new major
 staging branch, unless there is consensus from the Node.js releasers team to
@@ -1708,6 +1719,7 @@ Typical resolution: sign the release again.
 [Build issue tracker]: https://github.com/nodejs/build/issues/new
 [Node.js Snap management repository]: https://github.com/nodejs/snap
 [Release repository]: https://github.com/nodejs/Release
+[Require linear history]: https://github.com/nodejs/node/rules/714811
 [Semantic Versioning]: https://semver.org/
 [Snap]: https://snapcraft.io/node
 [`create-release-post.yml`]: https://github.com/nodejs/nodejs.org/actions/workflows/create-release-post.yml