Repository navigation
Conversation
|
Important Review skippedAuto reviews are disabled on base/target branches other than the default branch. Please check the settings in the CodeRabbit UI or the ⚙️ Run configuration
You can disable this status message by setting the Use the checkbox below for a quick retry:
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
|
The following accounts have interacted with this PR and/or linked issues. I will continue to update these lists as activity occurs. You can also manually ask me to refresh this list by adding the If you're merging code through a pull request on GitHub, copy and paste the following into the bottom of the merge commit message. To understand the WordPress project's expectations around crediting contributors, please review the Contributor Attribution page in the Core Handbook. |
wp/5.5 branch Actions: Always read Node.js version from .nvmrc filewp/5.5 branch Actions: Always read the Node.js version from .nvmrc
Part of #82938.
What?
Replaces the hardcoded
node-version: 12.xliteral in everyactions/setup-nodestep acrosswp/5.5's workflows withnode-version-file: '.nvmrc', so.nvmrcbecomes the one source of truth for the Node.js version this branch tests against:create-block.ymlbuildend2end-test.ymladmin-1,admin-2,admin-3,admin-4static-checks.ymlcheckunit-test.ymlunit-js,unit-phpThe
mobile-unit-jsjob's setup step isn't included: that job is removed earlier in this stack (#84995).Because the step's
namealso carried the version (Use Node.js 12.x), it is renamed toSetup Node.js— leaving a version in the step name would reintroduce exactly the duplication this change removes.This PR does not change which Node.js version is used.
.nvmrcstill reads12, so every job resolves to the same version as before; only the mechanism changes. Upgrading the pinned version is a separate concern, handled in the PR above this one.Why?
A version repeated as a literal string in eight places can drift — a future edit to one copy (or to
.nvmrc) has no mechanism keeping the others in step. Sourcing the version from.nvmrcvianode-version-fileremoves that duplication and matches the single-source-of-truth approach this project uses for Node version handling on every other branch it has repaired.wp/5.5has nonodeversion-testing matrix and nocheck-latest: trueanywhere in its.github/tree — everyactions/setup-nodecall already tested exactly one hardcoded Node.js version, so there was no matrix dimension to eliminate and no stale re-check flag to remove, unlike on this project's newerwp/6.xbranches. That is why this is framed as a single-source-of-truth fix rather than as thesingle-node-version-testingchange its sibling branches received.Use of AI Tools
This PR was created by Claude Code under my supervision. All code should be treated as AI-produced and not yet reviewed by a human until this PR is marked Ready for Review.