bug 记录
npm ERR! code E500
npm ERR! 500 Internal Server Error - GET http://42.159.157.231/jest-changed-files/-/jest-changed-files-24.9.0.tgz
项目引用了多个不同的registry的 npm包导致, 由于npm只能设置一个registry。所以不能同时从其它的registry上获取npm包。
因此需要对其它的npm包设置他们的scope, 实际开发中如果涉及到2个以上的npm npm registry则需要使用scope进行区分。
设置如下:
npm config set @scope:registry [registry url]
设置完成后可以功过npm config ls查看
@myscope:registry = "http://42.159.157.238/"
home = "https://www.npmjs.org"
registry = "https://registry.npmjs.org/"
网友评论