Closed
Description
If you run the following code snippet from inside of a workspace directory in an NPM package (like packages/<pkgname>
), the call to findYarnWorkspaceRoot()
in preferred-pm
ends up thinking that we're using Yarn.
import preferredPM from 'preferred-pm';
preferredPM(process.cwd()).then(pm => console.log(pm));
I'm not exactly sure how to fix this because you can't easily know if you're in an NPM workspace without recursively parsing the parent directories until you find a package.json
and see the workspaces
key.
Metadata
Metadata
Assignees
Labels
No labels