3 ms·
There's one thing you need to only think about once, and has the potential to save you a ton of time: profile your ZSH startup time! Stuff like NVM or Oh My ZS
by prodigycorp 7mo ago
There's one thing you need to only think about once, and has the potential to save you a ton of time: profile your ZSH startup time!
Stuff like NVM or Oh My ZSH will add a few seconds to your shell startup time.
- sva_ 7mo agoI can recommend powerlevel10k with instant prompt enabled. https://github.com/romkatv/powerlevel10k https://github.com/romkatv/powerlevel10k
- chrisweekly 7mo agogood call if you care about perf, fnm is better/faster/cleaner than nvm. (also, mise is able to manage "all the things", not just node) IME omzsh slowness usu relates to overloading it w plugins, which I've never found a need for...
- wewtyflakes 7mo agoAgreed. I lazy-load NVM to get around that: lazy_nvm() { unset -f nvm node npm npx [ -s "$NVM_DIR/nvm.sh" ] && . "$NVM_DIR/nvm.sh" } nvm() { lazy_nvm; nvm "$@"; } node() { lazy_nvm; node "$@"; } npm() { lazy_nvm; npm "$@"; } npx() { lazy_nvm; npx "$@"; }