LoginSignup
3
2

More than 5 years have passed since last update.

Raspberry Pi にnode brewを使ってnode.jsインストール

Posted at

概要

node brewを使ってnode.jsをインストール

環境

Raspberry Pi 2 Raspbian

nodebrewをインストール

$curl -L git.io/nodebrew | perl - setup
$echo 'export PATH=$HOME/.nodebrew/current/bin:$PATH' >> ~/.bashrc
$source .bashrc

nodebrewを使ってnode.jsをインストール

$nodebrew ls-all

インストール可能なnode.jsのバージョンを確認

v4.4.4をインストールする場合

$nodebrew install-binary v4.4.4

でv4.4.4のバイナリがインストールされる

※もしエラーが出るならnodebrew install v4.4.4のようにする
ただし、ビルドに2時間近く時間がかかってしまうので注意

$nodebrew use v4.4.4

使用するnodeのバージョンを指定する

$node -v

で、v4.4.4 と出力されていればインストール完了

3
2
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
3
2