Describe the bug
npm shim (running $HOME/.vite-plus/bin/npm) does not consult packageManager field. This is confusing. While node --version will properly print the version, which respect .node-version. npm --version will use resolved Node.js npm version not the one specified in packageManager field.
Steps to reproduce
- Install
npm@11.14.1: npm i -g npm@11.14.1.
- Set
packageManager field to npm@11.14.0: npm pkg set npm@11.14.0
- Run
vp install -- --verbose and then npm --version.
Expected:
Both commands should respect packageManager field. They both should print 11.14.0.
Actual:
vp install -- --verbose prints npm info using npm@11.14.0, which is expected, but npm --version print 11.14.1, which is confusing.
System Info
`vp v0.1.21`
`which npm` is `$HOME/.vite-plus/bin/npm`
Used Package Manager
npm
Validations
Describe the bug
npmshim (running$HOME/.vite-plus/bin/npm) does not consultpackageManagerfield. This is confusing. Whilenode --versionwill properly print the version, which respect.node-version.npm --versionwill use resolved Node.jsnpmversion not the one specified inpackageManagerfield.Steps to reproduce
npm@11.14.1:npm i -g npm@11.14.1.packageManagerfield tonpm@11.14.0:npm pkg set npm@11.14.0vp install -- --verboseand thennpm --version.Expected:
Both commands should respect
packageManagerfield. They both should print11.14.0.Actual:
vp install -- --verboseprintsnpm info using npm@11.14.0, which is expected, butnpm --versionprint11.14.1, which is confusing.System Info
Used Package Manager
npm
Validations