LoginSignup
36

More than 5 years have passed since last update.

Windowsにnode.jsを導入する方法

Posted at

windowsにnode.jsを導入する方法を簡単にまとめました。

windows8で試しました。

nvmwの導入

nvmw(Node Version Manager for Windows)はwindowsでnode.jsをバージョンごとに管理するためのツール。複数のバージョンのインストールや切り替えが楽にできる。詳細はhakobera / nvmwを参照。

 以下、導入手順

  • Gitとpythonが必要なのでなければインストール
  • ホームディレクトリにnvmwをクローン
git clone git://github.com/hakobera/nvmw.git "C:\Users\ユーザ名\.nvmw"
  • システムのプロパティの環境変数の設定で.nvmwへのパスを通す
  • コマンドプロンプトを起動し、nvmwを実行

D:\>nvmw

Node Version Manager for Windows

Usage:
  nvmw help                    Show this message
  nvmw install [version]       Download and install a [version]
  nvmw uninstall [version]     Uninstall a [version]
  nvmw use [version]           Modify PATH to use [version]
  nvmw ls                      List installed versions

Example:
  nvmw install v0.6.0          Install a specific version number
  nvmw use v0.6.0              Use the specific version

と表示されればnvmwの導入はOK。

node.jsのインストール

導入したnvmwを使ってnode.jsをインストールする。バージョン0.10.1をインストールしてみる。

nvmw install v0.10.1

これでインストール完了。

バージョンの切り替えはnvmw useで簡単にできる

D:\>nvmw use v0.9.8
Now using Node v0.9.8

D:\>node -v
v0.9.8

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
36