kikukawa's diary

都内で活動するシステムエンジニアが書いてます。 興味を持った技術やハマったポイント、自分用メモをつけてます。 最近はweb中心

nodebrewのインストールが失敗する

ドキュメントにも書いてありますが、自分用メモ

ワンライナーでやろうとしたら下記のようにエラーが発生しました。

$ curl -L git.io/nodebrew | perl - setup
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
139   279  139   279    0     0    152      0  0:00:01  0:00:01 --:--:-- 69750
Bareword found where operator expected at - line 3, near "400 Bad"
        (Missing operator before Bad?)
Bareword found where operator expected at - line 6, near "<p>Your"
        (Missing operator before Your?)
syntax error at - line 2, near "html>"
Execution of - aborted due to compilation errors.

その場合は、wgetとsetupを分けるとうまくいくことがあります。

$ wget git.io/nodebrew
$ perl nodebrew setup 
fetching nodebrew...
install nodebrew in $HOME/.nodebrew

========================================
Add path:

export PATH=$HOME/.nodebrew/current/bin:$PATH
========================================

https://github.com/hokaccha/nodebrew