PS D:\Repo\Marsen\Marsen.Node.Express> npm i -g gulp npm ERR! code ETIMEDOUT npm ERR! errno ETIMEDOUT npm ERR! network request to http://npm.mycompany.io/gulp failed, reason: connect ETIMEDOUT ***.***.***.***:80 npm ERR! network This is a problem 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! A complete log of this run can be found in: npm ERR! C:\Users\Mark Lin\AppData\Roaming\npm-cache\_logs\2018-07-29T07_17_25_263Z-debug.log
解法
一個簡單的方法是 VPN 回公司內部網路; 另一個方法是重新設定,
1 2 3 4 5
> npm get registry http://npm.mycompany.io > npm set registry https://registry.npmjs.org > npm get registry https://registry.npmjs.org