安装依赖时遇到以下问题,有可能是node或者npm版本高了,记录一下:
先是出现

npm ERR! code 128
npm ERR! git dep preparation failed
npm ERR! command C:\Program Files\nodejs\node.exe C:\Program Files\nodejs\node_modules\npm\bin\npm-cli.js install --force --cache=D:\npm-cache --prefer-offline=false --prefer-online=false --offline=false --no-progress 
--no-save --no-audit --include=dev --include=peer --include=optional --no-package-lock-only --no-dry-run

然后降低了node和npm版本

node版本:

v14.0.0

npm版本

6.14.10

然后到此报文

npm ERR! Error while executing:
npm ERR! C:\Program Files\Git\cmd\git.EXE ls-remote -h -t git://github.com/adobe-webplatform/eve.git
npm ERR!
npm ERR! fatal: unable to access 'https://github.com/adobe-webplatform/eve.git/': OpenSSL SSL_read: Connection was reset, errno 10054
npm ERR!
npm ERR! exited with error code: 128

解决:
1.

git config --global url."https://".insteadOf git://
npm install --registry=https://registry.npm.taobao.org

上面不行了直接npm i,一顿瞎操作就跑起来了

npm i
Logo

瓜分20万奖金 获得内推名额 丰厚实物奖励 易参与易上手

更多推荐