0
0

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 1 year has passed since last update.

nvmでnode16からnode18にするときエラー発生

Posted at

nvmでnode18を入れようとしたらエラーが発生した。
nvmを再インストールしたら解決したので記録として残す。

nvmでnode18を利用しようとしてエラー

> nvm version
1.1.9
> nvm install 18
Downloading node.js version 18.18.2 (64-bit)... 
Extracting...
Complete


Installation complete. If you want to use this version, type

nvm use 18.18.2

インストールまではできたが、nvm use 18.18.2で利用しようとするとエラーが発生した。

> nvm use 18.18.2
exit status 5: �A�N�Z�X�����ۂ����܂����B

exit status 1: ���ɑ��݂����t�@�C�����쐬���邱�Ƃ͂ł��܂����B

補足:エラーの文字化け

以下の方法でPowerShell文字コードを変えてみたが文字化けが解消しなかった。

文字コード確認
> chcp
現在のコード ページ: 932
文字コード変更
> chcp 65001

nvmの最新を再インストールしたら解決した。

  1. Windowsの「インストールされたアプリ」からインストール済みのnvm v1.1.9をアンインストール
  2. nvm v1.1.11を再インストール

> nvm version
1.1.11
> nvm install 18.18.2
Downloading node.js version 18.18.2 (64-bit)... 
Extracting node and npm...
Complete
npm v9.8.1 installed successfully.


Installation complete. If you want to use this version, type

nvm use 18.18.2
> nvm use 18.18.2
Now using node v18.18.2 (64-bit)
> node --version
v18.18.2
0
0
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
0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?