nvm_resolve_local_alias default
has bad performance
#3416
Labels
performance
This relates to anything regarding the speed of using nvm.
pull request wanted
This is a great way to contribute! Help us out :-D
Operating system and version:
macOS 14.5
nvm debug
output:nvm ls
output:How did you install
nvm
?install script in readme
What steps did you perform?
gdate
(fromcoreutils
) instead ofdate
to make%N
workWhat happened?
Found the
nvm_resolve_local_alias default
have bad performance.It took 2 seconds in my M3 chip macbookPro:
![image](https://private-user-images.githubusercontent.com/159167/361109694-4dcaf885-985b-4910-81a8-95235f5fe1b9.png?jwt=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJnaXRodWIuY29tIiwiYXVkIjoicmF3LmdpdGh1YnVzZXJjb250ZW50LmNvbSIsImtleSI6ImtleTUiLCJleHAiOjE3Mzg5MzkyNDcsIm5iZiI6MTczODkzODk0NywicGF0aCI6Ii8xNTkxNjcvMzYxMTA5Njk0LTRkY2FmODg1LTk4NWItNDkxMC04MWE4LTk1MjM1ZjVmZTFiOS5wbmc_WC1BbXotQWxnb3JpdGhtPUFXUzQtSE1BQy1TSEEyNTYmWC1BbXotQ3JlZGVudGlhbD1BS0lBVkNPRFlMU0E1M1BRSzRaQSUyRjIwMjUwMjA3JTJGdXMtZWFzdC0xJTJGczMlMkZhd3M0X3JlcXVlc3QmWC1BbXotRGF0ZT0yMDI1MDIwN1QxNDM1NDdaJlgtQW16LUV4cGlyZXM9MzAwJlgtQW16LVNpZ25hdHVyZT0yOGQ3MjQ5MjlhMjI1MDMyNDIyYmFiNzI2MWUwMDE4NjQ4MWY0MzAxNzU5OGYyODc2YjM3NzZkN2Q3ZGE0YmFiJlgtQW16LVNpZ25lZEhlYWRlcnM9aG9zdCJ9.uD675MelPkcZisgwPQw39O8Y7lt0oDyJHGLirdK_6sU)
Why it need 2 seconds to get default version? seems it's just a simple task.
What did you expect to happen?
nvm_resolve_local_alias default
should be quick, and save 2 seconds for my bash startup.Is there anything in any of your profile files that modifies the
PATH
?~/.bashrc
The text was updated successfully, but these errors were encountered: