npm does not install packages


I'm trying to install Electron, I've done it before but now when I do it (with clear sudo) it reaches a point where the console says:


node install.js

and there is nothing else that happens ... when trying to close the console it tells me that the process is running but it simply never materializes, before I installed it and it did not take long ...

This is the console output:

$ sudo npm install -g electron
/usr/local/bin/electron -> /usr/local/lib/node_modules/electron/cli.js

> [email protected] postinstall /usr/local/lib/node_modules/electron
> node install.js
asked by Cristofer Fuentes 17.11.2016 в 22:06

1 answer


According to this issue with exactly the same problem as you:

Apart from the version 1.3.1 there are two branches to install electron Official page

  • electron ( npm install electron--save-dev )
  • electron-prebuilt ( npm install electron-prebuilt --save-dev )

Either serves you, but prebuilt will be active until the end of 2016

You can run npm install electron --save-dev

For a better and cleaner installation I recommend

rm -rf ~/.electron/
rm -rf ~/.atom/
npm cache clear
npm install electron--save-dev
answered by 17.11.2016 / 22:17