-
-
Notifications
You must be signed in to change notification settings - Fork 8.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
bash snippet in README.md is very slow - here is a faster alternative #3508
Comments
Given that perl isn't guaranteed to be installed, I'm not sure it makes sense to add this to the readme. |
Maybe someone or some AI can translate it to bash? |
This comment has been minimized.
This comment has been minimized.
I wouldn't inflict AI output on anyone; if someone who's an expert in both bash and perl can manually translate it, that'd be great - otherwise it's best omitted. |
It is a given though, as all modern linux distros and macOS versions include perl installed and available in the system path by default. |
nvm works on all posix shells, and perl isn’t guaranteed to be available by posix. |
Operating system and version: Linux with bash and perl interpreter
The bash snippet suggested at https://github.com/nvm-sh/nvm?tab=readme-ov-file#bash is tremendously slow - on every single 'cd' the user types, there is a delay before reaching the target dir, regardless of whether the same or a different version of node needs to be used, and this can be counter-productive and annoying.
This is why I wrote the following .bashrc snippet, which can replace the aforementioned. Nevertheless, it uses Perl (even though it's a .bashrc snippet). However, if you do have Perl installed, it is incredibly faster than the (currently) official one.
The text was updated successfully, but these errors were encountered: