多node版本控制工具:nvm

更多文章可关注我的个人博客:https://seven777777.github.io/myblog/

有时候,不同的项目对于node版本的要求不同,如何快捷的控制我们电脑的node版本就成了我们需要考虑的问题

这里记录一下我平常使用的node版本控制工具:nvm

nvm is a version manager for node.js, designed to be installed per-user, and invoked per-shell. nvm works on any POSIX-compliant shell (sh, dash, ksh, zsh, bash), in particular on these platforms: unix, macOS, and windows WSL.

安装(windows)

传送门:https://github.com/coreybutler/nvm-windows/releases

网上有很多详细说明,这里就不赘述!

常用命令

  • nvm ls 查看已经安装的所有nodejs版本
  • nvm install 版本号,可安装指定版本的nodejs
  • nvm use 版本号,即可切换到指定版本
  • nvm current 当前使用版本
  • nvm uninstall 版本号,卸载指定版本
搴芳拾梦
欢迎关注的我的个人公众号【搴芳拾梦】
發表評論
所有評論
還沒有人評論,想成為第一個評論的人麼? 請在上方評論欄輸入並且點擊發布.
相關文章