在Mac下使用了淘宝的景象进行了安装,结果报错如下:
➜ electron-quick-start git:(master) ✗ cnpm install electron -g
/Users/tingyugetc/.nvm/versions/node/v6.9.4/bin/electron -> /Users/tingyugetc/.nvm/versions/node/v6.9.4/lib/node_modules/electron/cli.js
[email protected] postinstall /Users/tingyugetc/.nvm/versions/node/v6.9.4/lib/node_modules/electron
node install.js
/Users/tingyugetc/.nvm/versions/node/v6.9.4/lib/node_modules/electron/install.js:47
throw err
^
Error: connect ETIMEDOUT 52.216.0.96:443
at Object.exports._errnoException (util.js:1022:11)
at exports._exceptionWithHostPort (util.js:1045:20)
at TCPConnectWrap.afterConnect [as oncomplete] (net.js:1087:14)
npm ERR! Darwin 16.6.0
npm ERR! argv “/Users/tingyugetc/.nvm/versions/node/v6.9.4/bin/node” “/Users/tingyugetc/.nvm/versions/node/v6.9.4/bin/npm” “–registry=https://registry.npm.taobao.org” “–cache=/Users/tingyugetc/.npm/.cache/cnpm” “–disturl=https://npm.taobao.org/dist” “–userconfig=/Users/tingyugetc/.cnpmrc” “install” “electron” “-g”
npm ERR! node v6.9.4
npm ERR! npm v3.10.10
npm ERR! code ELIFECYCLE
npm ERR! [email protected] postinstall: node install.js
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the [email protected] postinstall script ‘node install.js’.
npm ERR! Make sure you have the latest version of node.js and npm installed.
npm ERR! If you do, this is most likely a problem with the electron package,
npm ERR! not with npm itself.
npm ERR! Tell the author that this fails on your system:
npm ERR! node install.js
npm ERR! You can get information on how to open an issue for this project with:
npm ERR! npm bugs electron
npm ERR! Or if that isn’t available, you can get their info via:
npm ERR! npm owner ls electron
npm ERR! There is likely additional logging output above.
npm ERR! Please include the following file with any support request:
npm ERR! /Users/tingyugetc/selfworkspace/js/electron/electron-quick-start/npm-debug.log
➜ electron-quick-start git:(master) ✗