Welcome to OGeek Q&A Community for programmer and developer-Open, Learning and Share
Welcome To Ask or Share your Answers For Others

Categories

0 votes
598 views
in Technique[技术] by (71.8m points)

node.js - How to change node version with nvm

I'm using yeoman to create a project, when I try to use gulp I run the cmd : gulp serve an error tells me that I need an older version of node (8.9.4), knowing that I've installed the latest version (10.14.1).

So i installed nvm to change the node version, I had to set it into path C:, then I run with success : nvm install 8.9.4 and when I try to use it : nvm use 8.9.4, its always the latest version that is used

enter image description here

if i try to use 8.10.0, then run node -v it tells me access refused, same to any node command

See Question&Answers more detail:os

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome To Ask or Share your Answers For Others

1 Reply

0 votes
by (71.8m points)

you need to use

nvm use 8.10.0

note that you need to run this command as administrator


与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
OGeek|极客中国-欢迎来到极客的世界,一个免费开放的程序员编程交流平台!开放,进步,分享!让技术改变生活,让极客改变未来! Welcome to OGeek Q&A Community for programmer and developer-Open, Learning and Share
Click Here to Ask a Question

...