5
5

More than 5 years have passed since last update.

Node.jsのカレントバージョンを確認する

Last updated at Posted at 2014-11-12

node.jsのカレントバージョンを http://nodejs.org/ から取得します。

install_nodejs.sh
#!/bin/sh
source ~/.nvm/nvm.sh

# カレントバージョンを取得
node_ver=`
  curl -s http://nodejs.org/ |
  grep "Current Version"     |
  perl -pe "s/.+(v\d+\.\d+\.\d+)/\1/g"
` 

# カレントバージョンをnvmでインストール
nvm install $node_ver
5
5
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
5
5