Closed aduh95 closed 5 months ago
This PR still lacks a protection for the built-in package manager (Corepack should not silently use a non-official Yarn/PNPM/npm version, unless there's some env variable that explicitly opt-into that)
I'm sure how to handle the corepack pkgName --version
, when pkgName
is not one of the supported package managers – I guess we'd need a new command, e.g. corepack run pkgName --version
, but I figured I'd better get some reviews first to see if I'm going in a wrong direction.
Code could use some cleanup, I'm not very proficient in TS, if someone wants to refactor to make it more readable, be my guest.
I think we dropped support for Node.js 19.x when it went EOL a while back, although I reckon it wouldn't hurt to specify that in the engines field.
I reckon it wouldn't hurt to specify that in the engines field.
Keep in mind that's a breaking change, could you do it in a separate PR?
Fixes: https://github.com/nodejs/corepack/issues/354