npm ERR!更新角4
问题描述:
我试图用这个COMAND更新Angular2到角4:npm ERR!更新角4
npm install @angular/[email protected] @angular/[email protected] @angular/[email protected] @angular/[email protected] @angular/[email protected] @angular/[email protected] @angular/[email protected] @angular/[email protected] @angular/[email protected] @angular/[email protected] @angular/[email protected] [email protected] --save
,并显示此错误:
npm ERR! code ECONNRESET
npm ERR! errno ECONNRESET
npm ERR! syscall read
npm ERR! network read ECONNRESET
npm ERR! network This is most likely not a problem with npm itself
npm ERR! network and is related to network connectivity.
npm ERR! network In most cases you are behind a proxy or have bad network settings.
npm ERR! network
npm ERR! network If you are behind a proxy, please make sure that the
npm ERR! network 'proxy' config is set properly. See: 'npm help config'
npm ERR! shasum check failed for C:\Windows\temp\npm-3816-28e571ea\registry.npmjs.org\typescript\-\typescript-2.4.1.tgz
npm ERR! Expected: c3ccb16ddaa0b2314de031e7e6fee89e5ba346bc
npm ERR! Actual: e123d8d94948e846a2c38ac3ffea38ea349ec2ec
npm ERR! From: https://registry.npmjs.org/typescript/-/typescript-2.4.1.tgz
npm ERR! A complete log of this run can be found in:
npm ERR! C:\U\Ov15\AppData\Roaming\npm-cache\_logs\2017-07-07T02_21_38_894Z-debug.log
任何人可以帮助我吗?
答
你是否设置了你的npm代理?
NPM配置设置HTTP代理http://username:[email protected]:port
NPM配置设置HTTPS代理http://username:[email protected]:port
+0
是的,我做到了,但它不起作用。 –
清除您的NPM缓存,再次尝试。 'NPM缓存clean' – cgTag
如果通过公司网络访问,你必须通过执行NPM配置设置代理设置代理的 “http://%5C : @: /” NPM配置一套HTTPS代理“ http:// %5C : @: /“。或者你可以通过执行“npm config edit”手动编辑配置文件。 –