Seguí esta esencia https://gist.github.com/Goddard/5500157 para instalar nodejs y npm, pero después de ejecutarla no se pudo ejecutar ni node --version ni npm --version, dando un error de comando no encontrado. Pude desinstalar nodejs, pero tuve que ir al directorio temporal descrito en el script y hacer una desinstalación para que npm se vaya.
Ahora, en un intento de instalar nodejs y npm nuevamente, utilicé este enlace en su lugar http://www.andreagrandi.it/2013/02/08/how-to-install-latest-stable-node-js-on-ubuntu/ , pero si intento instalar ambos nodejs y npm juntos, aparece este mensaje de error.
sudo apt-get install nodejs npm
The following packages have unmet dependencies:
nodejs : Conflicts: npm
E: Unable to correct problems, you have held broken packages.
Si solo instalo nodejs eso funciona bien.
sudo apt-get install nodejs
node --version
v0.10.15
Pero ahora si trato de instalar npm me da este mensaje de error
sudo apt-get install npm
The following packages have unmet dependencies:
npm : Depends: nodejs (>= 0.6.19~dfsg1-3) but it is not going to be installed
Depends: nodejs-dev
Depends: node-node-uuid but it is not going to be installed
Depends: node-request but it is not going to be installed
Depends: node-mkdirp but it is not going to be installed
Depends: node-minimatch but it is not going to be installed
Depends: node-semver but it is not going to be installed
Depends: node-ini but it is not going to be installed
Depends: node-graceful-fs but it is not going to be installed
Depends: node-abbrev but it is not going to be installed
Depends: node-nopt but it is not going to be installed
Depends: node-fstream but it is not going to be installed
Depends: node-rimraf but it is not going to be installed
Depends: node-tar but it is not going to be installed
Depends: node-which but it is not going to be installed
E: Unable to correct problems, you have held broken packages.
Estoy usando Ubuntu 13.04. Cualquier ayuda es apreciada. No sé mucho sobre node.js y npm. Estaba tratando de comenzar a aprender cómo usarlos, por lo que probablemente mi experiencia esté demostrando.