tmp
Friday, January 22, 2016
ubuntu12.04 のnpmとnodeを最新にする
install npm ```bash $ apt-get update $ apt-get install npm $ npm -v 1.4.3 ``` update npm ```bash $ npm install npm -g npm http GET https://registry.npmjs.org/npm npm ERR! Error: failed to fetch from registry: npm ``` ここでエラーが出るのでregistryを変える(元は`https://registry.npmjs.org/`) ```bash $ npm config set registry http://registry.npmjs.org/ ``` update npm ```bash $ npm install npm -g $ npm -v 3.5.3 $ node -v v0.6.12 ``` nodeが古すぎて`n`をinstallできないので以下を行う ```bash $ apt-get install python-software-properties $ apt-add-repository ppa:chris-lea/node.js $ apt-get update $ apt-get install nodes $ node -v v0.10.37 ``` さらに`n`をinstallしてnodeのバージョンを上げる ```bash $ npm install n -g $ n 4.2.6 $ node -v v4.2.6 ``` ##参照 * http://stackoverflow.com/questions/12913141/message-failed-to-fetch-from-registry-while-trying-to-install-any-module * https://easyengine.io/tutorials/nodejs/node-js-npm-install-ubuntu/
No comments:
Post a Comment
Newer Post
Older Post
Home
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment