LoginSignup
1
1

More than 5 years have passed since last update.

anyenv 基本的な使い方

Posted at
  • 一つのマシンでNode.js,Python,Ruby 等の複数言語を扱うかもしれないので、anyenvをインストールしてみた
  • 基本的には公式通りでOK

anyenvインストール

  • インストール
git clone https://github.com/riywo/anyenv ~/.anyenv
echo 'export PATH="$HOME/.anyenv/bin:$PATH"' >> ~/.bash_profile
echo 'eval "$(anyenv init -)"' >> ~/.bash_profile
exec $SHELL -l
  • 確認
    • anyenv -h

anyenvでndenvをインストール

  • インストール
anyenv install ndenv
exec $SHELL -l
  • 確認
    • anyenv version

ndenvでNode.jsをインストール

  • インストール可能なバージョン一覧
    • ndenv install -l
  • インストール
    • ndenv install v8.9.1
  • インストールされているバージョン一覧
    • ndenv versions
  • バージョン切り替え(global)
    • ndenv global v8.9.1
  • 確認
    • node -v
    • npm -v

参考

1
1
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
1
1