Now that package nodejs-fake does not exist anymore, what is the suggested way to go about this?
EDIT: the wiki has been updated.
Git Clone URL: | https://aur.archlinux.org/nvm.git (read-only, click to copy) |
---|---|
Package Base: | nvm |
Description: | Node Version Manager - Simple bash script to manage multiple active node.js versions |
Upstream URL: | https://github.com/nvm-sh/nvm |
Licenses: | MIT |
Submitter: | tomwadley |
Maintainer: | tomwadley |
Last Packager: | tomwadley |
Votes: | 298 |
Popularity: | 5.85 |
First Submitted: | 2015-03-14 21:57 (UTC) |
Last Updated: | 2024-08-27 22:35 (UTC) |
Now that package nodejs-fake does not exist anymore, what is the suggested way to go about this?
EDIT: the wiki has been updated.
@tomwadley You are right. Thanks! In the readme at Github, sourcing nvm is mentioned after the second "command -v nvm". I stopped after the first.
@Twiki you need to "source" nvm into your environment before you can run it. Look at the post-install instructions here that you may have missed https://aur.archlinux.org/cgit/aur.git/tree/nvm.install?h=nvm
Just installed, next to main Arch repo's already installed v10.8.0.
Result: nvm not found. command verify produces no output. nvm does exist.
[twiki@21stcentury 4.4.23 ~]# nvm run node --version
bash: nvm: command not found
[twiki@21stcentury 4.4.23 ~]# command -v nvm
[twiki@21stcentury 4.4.23 ~]# whereis nvm
nvm: /usr/share/nvm
[twiki@21stcentury 4.4.23 ~]#
-._. What went wrong?
Note that for init-nvm.sh
may not work for every Zsh user, such as one who wants separate path for .zcompdump
files, because option is hardcoded in bash_completion
. I fell back to zsh-completions
.
Hi Fandekasp - do you have a "prefix" line in your ~/.npmrc
, perhaps? If so, remove it.
If that doesn't work or apply, please file a new issue on the nvm github repo. Thanks!
Recently, I'm getting the following message everytime I open a shell
nvm is not compatible with the npm config "prefix" option: currently set to ""
Run npm config delete prefix
or nvm use --delete-prefix v10.5.0 --silent
to unset it.
Uninstalling and re-installing nvm didn't fix the issue. Running the 2 commands suggested doesn't change anything either
@Depado This package doesn't create that file. I think that file is created by the official install.sh if you tell it to enable nvm for all users on the machine (an idea that might be worth looking into for this package actually). I guess you should follow the official uninstall instructions if you've used the official install.sh script.
Just a heads up, when uninstalling the package, /etc/profile.d/nvm.sh isn't deleted. This caused my X session to fail on startup. (I have no idea if that's just me or if that happened to someone else)
@givemeurhats The nodejs-fake you were talking about does not exist...
Pinned Comments
tomwadley commented on 2020-09-04 22:14 (UTC) (edited on 2020-09-04 22:15 (UTC) by tomwadley)
Due to the way nvm is designed, you have to source it before you can use it:
You will probably want that in your shell startup file, e.g.:
See nvm.install or the upstream README for more details.