Closed deleteme closed 3 years ago
I encountered the following error when running nvm install.
nvm install
~/.config/fish/functions/_nvm_index_update.fish (line 7): Invalid redirection target: ' >$index.temp 2>/dev/null && command mv $index.temp $index && return ^ in function '_nvm_index_update' called on line 32 of file ~/.config/fish/functions/nvm.fish in function 'nvm' with arguments 'install' usage: mv [-f | -i | -n] [-v] source target mv [-f | -i | -n] [-v] source ... directory nvm: Invalid index or unavailable host: ""
I found these two related issues #130 and #139 but since I also experienced the error I figured I could track down some reproduction steps.
In Shell 1
curl -sL https://git.io/fisher | source && fisher install jorgebucaran/fisher
fisher install jorgebucaran/nvm.fish
In Shell 2
The attached video demonstrates how to reproduce the bug:
https://user-images.githubusercontent.com/9389/108633557-b3906d00-7429-11eb-838f-d43f92cde11c.mov
The error doesn't happen in new shells. When I noticed that nvm worked in a previously open shell, I assumed that nvm install would work too.
nvm
Fixed by making nvm_data and nvm_mirror universally scoped, so that they're immediately available to all running sessions after installing the plugin. Thank you! 💯
nvm_data
nvm_mirror
I encountered the following error when running
nvm install
.I found these two related issues #130 and #139 but since I also experienced the error I figured I could track down some reproduction steps.
In Shell 1
curl -sL https://git.io/fisher | source && fisher install jorgebucaran/fisher
fisher install jorgebucaran/nvm.fish
In Shell 2
The attached video demonstrates how to reproduce the bug:
https://user-images.githubusercontent.com/9389/108633557-b3906d00-7429-11eb-838f-d43f92cde11c.mov
The error doesn't happen in new shells. When I noticed that
nvm
worked in a previously open shell, I assumed thatnvm install
would work too.