当前位置:网站首页>NVM introduction, NVM download, installation and use (node version management)
NVM introduction, NVM download, installation and use (node version management)
2022-04-23 21:25:00 【Sister Chunfeng】
One 、nvm Introduce
At work , We may be doing it at the same time 2 Development of one or more different projects , The needs of each project are different , Furthermore, different projects must rely on different versions of NodeJS Running environment , In this case , For maintaining multiple versions of node It will be a very troublesome thing ,nvm It is to solve this problem that , It can easily carry out multiple tests on the same device node Switch between versions .
Two 、nvm Download, install and use
2.1 nvm download
Installation package download address :https://github.com/coreybutler/nvm-windows/releases ,windows System download nvm-setup.zip Installation package
2.2 nvm install
If it has been installed separately on the computer before node, To uninstall first , Then decompress nvm-setup.zip Installation package , Enter the unzipped folder , double-click exe Suffix file for installation
The following interface is to select and install nvm The path of , You can change the installation path , General default path
This is nodejs Installation position of , without nodejs Create a new folder ( Later, it was found that he would automatically generate a shortcut )
Open window command window+x choice windows PowerShell
After installation, enter nvm -v View version .
Set below setting.txt, Ignore not set
After installation , Find the path to install , Some simple configurations , open setting.txt
Add these two lines of code later
node_mirror: https://npm.taobao.org/mirrors/node/
npm_mirror: https://npm.taobao.org/mirrors/npm/
2.3 nvm Use
nvm off // Ban node.js version management ( Don't unload anything )
nvm on // Enable node.js version management
nvm install <version> // install node.js The name of version It's the version number for example :nvm install 8.12.0
nvm uninstall <version> // uninstall node.js Yes, orders , Uninstall the specified version of nodejs, When the installation fails, uninstall and use
nvm ls // Displays all installed node.js edition
nvm list available // Displays all that can be installed node.js Version of
nvm use <version> // Switch to use the specified nodejs edition
nvm v // Show nvm edition
nvm install stable // Install the latest stable version
See the picture below :
If you use node -v, Tips node:command not found, You need to nvm use node Version number , See the picture below
The currently used... Is shown below node The version is 14.16.1
版权声明
本文为[Sister Chunfeng]所创,转载请带上原文链接,感谢
https://yzsam.com/2022/110/202204200620163887.html
边栏推荐
- 小米手机全球已舍弃“MI”品牌,全面改用“xiaomi”全称品牌
- How to make Jenkins job run automatically after startup
- Introduction to tensorrt
- setInterval、setTimeout、requestAnimationFrame
- Question brushing plan - depth first search DFS (I)
- Deno 1.13.2 发布
- ubutnu20安装CenterNet
- The computer is out of power. How did I pass the terrible interview of Tencent cloud?
- [leetcode sword finger offer 10 - II. Frog jumping steps (simple)]
- Leetcode-279-complete square number
猜你喜欢
Rust更适合经验较少的程序员?
ROS learning notes - tutorial on the use of ROS
[leetcode refers to offer 10 - I. Fibonacci sequence (simple)]
How to make Jenkins job run automatically after startup
一文解决浏览器跨域问题
Xiaomi mobile phone has abandoned the "Mi" brand all over the world and switched to the full name brand of "Xiaomi"
How Axure installs a catalog
Minecraft 1.12.2模组开发(四十三) 自定义盾牌(Shield)
[※ leetcode refers to offer 32 - II. Print binary tree II from top to bottom (simple)]
Reentrant function
随机推荐
Assertionerror: invalid device ID and runtimeerror: CUDA error: invalid device ordinal
[leetcode refers to offer 21. Adjust the array order so that odd numbers precede even numbers (simple)]
Addition, deletion, modification and query of MySQL advanced table
C knowledge
thinkphp5+数据大屏展示效果
Xiaomi mobile phone has abandoned the "Mi" brand all over the world and switched to the full name brand of "Xiaomi"
Reference of custom message in ROS function pack failed
setInterval、setTimeout、requestAnimationFrame
Display, move, rotate
使用mbean 自动执行heap dump
Crisis is opportunity. Why will the efficiency of telecommuting improve?
How to make Jenkins job run automatically after startup
41. The first missing positive number
Resolve the "chromedriver executable needs to be in path" error
Normalized transforms in pytorch The real calculation process of normalize
如何发挥测试策略的指导性作用
Graph traversal - BFS, DFS
[leetcode refers to offer 52. The first common node of two linked lists (simple)]
Deep analysis of C language pointer (Part I)
CUDA, NVIDIA driver, cudnn download address and version correspondence