Conversation
Contributor
There was a problem hiding this comment.
Pull request overview
This PR removes the deprecated use-node-version CLI option and pnpm.executionEnv.nodeVersion manifest field as part of a breaking change. Users should now use devEngines.runtime and engines.runtime fields instead, or use pnpm dlx node@runtime:<version> for running Node.js CLI tools with specific versions.
Key Changes:
- Removed automatic Node.js version switching functionality based on manifest configuration
- Removed
--use-node-versionCLI option from all commands - Updated
dlxcommand test to use new--package=node@runtime:<version>syntax
Reviewed changes
Copilot reviewed 39 out of 40 changed files in this pull request and generated no comments.
Show a summary per file
| File | Description |
|---|---|
| workspace/find-packages/test/fixtures/warning-for-non-root-project/packages/foo/package.json | Removed executionEnv from test fixture's pnpm object |
| workspace/find-packages/test/fixtures/warning-for-non-root-project/packages/bar/package.json | Removed executionEnv from test fixture's pnpm object |
| workspace/find-packages/src/index.ts | Removed whitelist check for non-root pnpm fields; now warns for all pnpm fields in non-root projects |
| releasing/plugin-commands-publishing/test/recursivePublish.ts | Removed test for pnpm.executionEnv.nodeVersion during publishing |
| releasing/plugin-commands-publishing/src/publish.ts | Removed prepareExecutionEnv call from lifecycle script execution |
| releasing/plugin-commands-deploy/test/shared-lockfile.test.ts | Removed executionEnv from test manifest fixtures |
| releasing/plugin-commands-deploy/src/createDeployFiles.ts | Removed merging of non-root pnpm fields into deploy manifest |
| pnpm/test/run.ts | Removed test for recursive run with different node versions |
| pnpm/test/install/lifecycleScripts.ts | Removed tests for workspace packages using executionEnv.nodeVersion |
| pnpm/test/exec.ts | Removed entire test file for exec with executionEnv |
| pnpm/test/dlx.ts | Updated test to use new --package=node@runtime:<version> syntax instead of --use-node-version |
| pnpm/test/cli.ts | Removed test for useNodeVersion in workspace manifest |
| pnpm/src/main.ts | Removed prepareExecutionEnv logic and simplified nodeVersion handling |
| pnpm-lock.yaml | Removed @pnpm/plugin-commands-env dependency from plugin-commands-installation |
| pkg-manager/plugin-commands-installation/tsconfig.json | Removed reference to plugin-commands-env package |
| pkg-manager/plugin-commands-installation/src/update/index.ts | Removed prepareExecutionEnv parameter |
| pkg-manager/plugin-commands-installation/src/installDeps.ts | Removed PrepareExecutionEnv type and parameter |
| pkg-manager/plugin-commands-installation/src/install.ts | Removed prepareExecutionEnv binding |
| pkg-manager/plugin-commands-installation/src/dedupe.ts | Removed prepareExecutionEnv binding |
| pkg-manager/plugin-commands-installation/src/add.ts | Removed prepareExecutionEnv binding |
| pkg-manager/plugin-commands-installation/package.json | Removed @pnpm/plugin-commands-env dependency |
| pkg-manager/core/src/install/index.ts | Removed prepareExecutionEnv from lifecycle options |
| pkg-manager/core/src/install/extendInstallOptions.ts | Removed PrepareExecutionEnv type and option |
| packages/types/src/package.ts | Removed executionEnv from PnpmSettings interface |
| packages/types/src/index.ts | Removed export of env.ts types |
| packages/types/src/env.ts | Deleted entire file containing execution environment types |
| packages/constants/src/index.ts | Removed USEFUL_NON_ROOT_PNPM_FIELDS constant |
| exec/plugin-commands-script-runners/test/index.ts | Removed test for running scripts with node version |
| exec/plugin-commands-script-runners/src/runRecursive.ts | Removed prepareExecutionEnv logic from recursive script execution |
| exec/plugin-commands-script-runners/src/run.ts | Removed use-node-version option and executionEnv handling |
| exec/plugin-commands-script-runners/src/exec.ts | Simplified path preparation by removing per-package execution env logic |
| exec/plugin-commands-script-runners/src/dlx.ts | Removed use-node-version option type |
| exec/lifecycle/src/runLifecycleHook.ts | Removed prepareExecutionEnv call from lifecycle hook execution |
| env/plugin-commands-env/test/node.test.ts | Removed test for prepareExecutionEnv function |
| env/plugin-commands-env/src/node.ts | Removed prepareExecutionEnv export and implementation |
| env/plugin-commands-env/src/index.ts | Removed prepareExecutionEnv from exports |
| config/config/test/index.ts | Updated tests to use fetchRetries instead of useNodeVersion for testing environment variable and CLI option precedence |
| config/config/src/getOptionsFromRootManifest.ts | Removed executionEnv from options mapping |
| config/config/src/Config.ts | Removed useNodeVersion from Config interface |
| .changeset/small-numbers-joke.md | Added changeset documenting the breaking change |
Files not reviewed (1)
- pnpm-lock.yaml: Language not supported
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Instead of
use-node-versionusedevEngines.runtime.Instead of
pnpm --config.useNodeVersion=20.0.0 <node.js cli tool>, usepnpm dlx node@runtime:20.0.0 <node.js cli tool>