Comments (7)
Well, I've never encountered this particular issue, but I suppose anything is possible. Maybe you stumbled upon some extremely rare edge case that only a select few have ever experienced. Or maybe it's just the limitations of Fish's subpar concurrency. I may circle back to this later, but I'll keep it closed for now.
from nvm.fish.
I see. But you still should be able to use multiple nodes at the same time in different terminals, since path changes are local, yes?
from nvm.fish.
I see. But you still should be able to use multiple nodes at the same time in different terminals, since path changes are local, yes?
Yes I can, but when this happens the terminal in which the failure happened will have the Homebrew node in the path until I re-run activate_directory_node_version
:
awk: can't open file /Users/grant/.local/share/nvm/.index.temp
source line number 6
nvm: Invalid version number or alias: "18.14.2"
Welcome to fish, the friendly interactive shell
Type `help` for instructions on how to use fish
~/c/a/s/web> node --version
v19.6.1
~/c/a/s/web> which node
/usr/local/bin/node
~/c/a/s/web> activate_directory_node_version
Now using Node v18.14.2 (npm 9.5.0) ~/.local/share/nvm/v18.14.2/bin/node
~/c/a/s/web> node --version
v18.14.2
~/c/a/s/web> which node
/Users/grant/.local/share/nvm/v18.14.2/bin/node
While the other terminal will (correctly) have the NVM node in the path from the beginning:
Now using Node v18.14.2 (npm 9.5.0) ~/.local/share/nvm/v18.14.2/bin/node
Welcome to fish, the friendly interactive shell
Type `help` for instructions on how to use fish
~/c/a/s/web> node --version
v18.14.2
~/c/a/s/web> which node
/Users/grant/.local/share/nvm/v18.14.2/bin/node
from nvm.fish.
To clarify, this only happens within VS Code?
from nvm.fish.
To clarify, this only happens within VS Code?
It happens in VS Code but it’s not a VS Code-specific bug.
I can also trigger this by opening two Terminal.app tabs to directories containing .node-version
files, saving them with “Window -> Save Windows as Group…”, then opening that group with “Window -> Open Window Group” (might not happen every time, but happened for me in 2/3 attempts). So I think it’s safe to say this can happen in any context where nvm install
is called simultaneously in two or more terminals.
from nvm.fish.
May I ask why you are trying to run the install command simultaneously in multiple terminals? Given that this is outside the scope of the project, I am going to close this issue (at least for now).
from nvm.fish.
May I ask why you are trying to run the install command simultaneously in multiple terminals? Given that this is outside the scope of the project, I am going to close this issue (at least for now).
I’ll often have two terminal tabs open in VS Code, and when I reopen the project they’re restored simultaneously.
I understand this is an unusual use case — for now I’ve been using fnm to solve this. Thanks for this project, it’s served me well for years!
from nvm.fish.
Related Issues (20)
- `nvm_default_version` not working to set default version of node HOT 6
- nvm_default_version not working for setting default HOT 2
- Auto-expand tilde (home directory) for universal variable `nvm_data` HOT 12
- VSCode debug "can't find Node.js binary" HOT 4
- fish: Unknown command: node HOT 5
- support for man pages HOT 5
- Node is unavailable in new shells HOT 11
- nvim + nvm configuration HOT 5
- Doesn't get installed with fisher HOT 2
- `nvm alias` HOT 5
- download url wrong when `nvm_arch=x64-musl` HOT 2
- nvm install-latest-npm equivalent HOT 4
- Does not handle env variables at startup in VSCode environment (OSX) HOT 20
- lsr(list-remote), install give me error and list(ls) give me nothing HOT 11
- getting error on line 225 in nvm.fish using fish shell v3.4 & 3.6 HOT 3
- Add nvm exec and nvm run commands HOT 10
- Need to reinstall node on session restart HOT 2
- macOS / brew: After "nvm use default", still node from brew is on path HOT 27
- nvm-exec script HOT 3
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from nvm.fish.