jorgebucaran / nvm.fish

The Node.js version manager you'll adore, crafted just for Fish
https://git.io/nvm.fish
MIT License
2.13k stars 71 forks source link

Do I have to set the node version every time? #149

Closed 1ak31sha closed 3 years ago

1ak31sha commented 3 years ago

hey hoping you can help me with this issue.

everyday when i start my terminal, i have to re-set my node version. my global version is v15 but my work repo uses v14. not only that, but i also have to reinstall nvm.fish everyday. heres my daily workflow below...hoping there is a way that i dont have to reinstall and re-set the node version everyday.

Screen Shot 2021-03-23 at 10 49 27 AM

other info: fish, version 3.1.2 let me know if i can provide anything else. thanks!

jorgebucaran commented 3 years ago

The nvm install command activates the specified Node version only in the current environment. To set the default version in new shells use set --universal nvm_default_version to the version you want.

If you want to lock a specific version of Node for different projects or directories, create an .nvmrc file with the version you want, then run nvm install from there.

About reinstalling nvm, that's extremely odd, and I have no idea how you could've wound up in that state.

Can you create a new issue in the Fisher repo, sharing the contents of your config.fish, ls of your ~/.config/fish/functions, and set --show fish_function_path?

1ak31sha commented 3 years ago

ok thanks! i will do that