この記事は公開されてから1年以上経過しています。情報が古い可能性がありますので、ご注意ください。
注) macosxでの手順です。
nodebrew
nodebrewはバージョンアップの速いnode.jsを、複数バージョン管理するためのツールです。
セットアップ
curl
$ curl https://raw.github.com/hokaccha/nodebrew/master/nodebrew | perl - setup
wget
$ wget https://raw.github.com/hokaccha/nodebrew/master/nodebrew
$ perl nodebrew setup
パス設定
.nodebrew内にnode.js がインストールされるので、PATH通します。
.zshrcや.bashrc などのファイルにこれを足せば良いだけです。
export PATH=$HOME/.nodebrew/current/bin:$PATH
$ source ~/.bashrc
Node.js指定
$ nodebrew install latest # 最新
$ nodebrew ls-remote #リモートのバージョン一覧
$ nodebrew install 0.9.12 #0.9.12をインストール
$ nodebrew install 0.8.18 #0.0.8.18をインストール
$ nodebrew use 0.9.12 #0.9.12を使用する
npm
Node.jsのバージョンマネジャーです。
% curl http://npmjs.org/install.sh | sh
% npm --version #確認
grunt
gruntは、Node.js上で動く、JavaScriptのためのビルドツールです。
$ npm install -g grunt
$ grunt --version #確認