Closed
Description
Current Behavior:
I have a package.json like,
{
"dependencies": {
... mix of private public packages
},
"devDependencies": {
... mix of private public packages
}
When I run, npm install --only dev
It still,
- Looks for packages in
dependencies
block. - Tries to build the packages in
dependencies
block.
Expected Behavior:
It should completely ignore the dependencies
block and only look for, And build dependencies in devDependencies
block.
Steps To Reproduce:
- Put the following
package.json
in a folder and run,npm install --only dev
.
{
"dependencies": {
"@smolcompany/auth": "0.7.0",
"bcrypt": "1.0.2",
"moment": "2.10.6"
},
"devDependencies": {
"source-map-support": "^0.5.19",
"ts-node": "^9.0.0",
"typescript": "^4.0.5"
}
}
I get this error,
npm ERR! code E404
npm ERR! 404 Not Found - GET https://registry.npmjs.org/@smolcompany%2fauth - Not found
npm ERR! 404
npm ERR! 404 '@smolcompany/[email protected]' is not in the npm registry.
npm ERR! 404 You should bug the author to publish it (or use the name yourself!)
npm ERR! 404
npm ERR! 404 Note that you can also install from a
npm ERR! 404 tarball, folder, http url, or git url.
npm ERR! A complete log of this run can be found in:
npm ERR! /home/ishan/.npm/_logs/2021-03-08T18_33_35_121Z-debug.log
Environment:
OS: Arch linux
Node: 14.15.4(I have also replicated it with node 15.11)
npm: 7.6.1