5
1

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

More than 5 years have passed since last update.

nodenvをアップデートする

Posted at

anyenvで管理してるnodenvのアップデート方法。
nodenv update でサクッといけると思ったが、いけなかったので備忘録。

結論

一度アンインストールして再インストールする。

$ anyenv uninstall nodenv
$ anyenv install nodenv

これでnodenv install -l すれば最新版までリストアップされるはず。

試したこと

1. anyenvをアップデートする

anyenvをアップデートしたら、管理下のnodenvも自動的にアップデートされるのでは?との思いで決行。

$ brew upgrade anyenv

変化なし。撃沈。

2. nodenvアップデートコマンドを実行する

nodenvにもアップデートコマンドがあるのかなと思い、勢いで実行。

$ nodenv update

そんなコマンドはありませんでした。ちゃんとhelpを確認しましょう

$ nodenv help
Usage: nodenv <command> [<args>]

Some useful nodenv commands are:
   commands    List all available nodenv commands
   local       Set or show the local application-specific Node version
   global      Set or show the global Node version
   shell       Set or show the shell-specific Node version
   install     Install a Node version using node-build
   uninstall   Uninstall a specific Node version
   rehash      Rehash nodenv shims (run this after installing executables)
   version     Show the current Node version and its origin
   versions    List installed Node versions
   which       Display the full path to an executable
   whence      List all Node versions that contain the given executable

See `nodenv help <command>' for information on a specific command.
For full documentation, see: https://github.com/nodenv/nodenv#readme

3. 一度アンインストールして再インストール

こちらの記事にすべて書いてありました。

anyenvによるnode.jsの更新 | ゴンの気まぐれなるままに

ありがたや。

$ anyenv uninstall nodenv
$ anyenv install nodenv

無事アップデート完了。

5
1
1

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
1

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?