zsh initialization performance #3410
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
shell: zsh
Operating system and version:
nvm debug
output:nvm ls
output:How did you install
nvm
?install script in readme
What steps did you perform?
Opening a Terminal (Ubuntu)
What happened?
The terminal take long time since a few days to "initialise", I am using zsh and oh-my-zsh
In addition the nvm command are also slow
I have zprofed
num calls time self name
What did you expect to happen?
Quicker access to my cmd line as now it take a few seconds to load it
Is there anything in any of your profile files that modifies the
PATH
?zmodload zsh/zprof
if [[ -r "${XDG_CACHE_HOME:-$HOME/.cache}/p10k-instant-prompt-${(%):-%n}.zsh" ]]; then
source "${XDG_CACHE_HOME:-$HOME/.cache}/p10k-instant-prompt-${(%):-%n}.zsh"
fi
Path to your oh-my-zsh installation.
export ZSH="$HOME/.oh-my-zsh"
ZSH_THEME="powerlevel10k/powerlevel10k"
zstyle ':omz:update' mode auto # update automatically without asking
zstyle ':omz:plugins:nvm' lazy yes
plugins=(git python docker docker-compose zsh-autosuggestions)
source $ZSH/oh-my-zsh.sh
alias dcd="docker compose down"
alias dcu="docker compose up -d"
alias dcl="() {docker logs -f $1}"
alias dcr="dcd ; dcu"
export NVM_DIR="$HOME/.nvm"
[ -s "$NVM_DIR/nvm.sh" ] && . "$NVM_DIR/nvm.sh" # This loads nvm
[ -s "$NVM_DIR/bash_completion" ] && . "$NVM_DIR/bash_completion" # This loads nvm bash_completion
export PATH="$NVM_DIR:$PATH"
export PATH="/usr/local/bin:$PATH"
export ANDROID_HOME=/home/devlin/Android/Sdk
export ANDROID_NDK=/home/devlin/Android/Sdk/ndk
export PATH="$HOME/Developments/flutter/bin:$PATH"
export PATH="/home/devlin/Developments/flutter/bin:$PATH"
export PATH="/opt/oracle/instantclient_21_5:$PATH"
export LD_LIBRARY_PATH="/opt/oracle/instantclient_21_5:$LD_LIBRARY_PATH"
Load Angular CLI autocompletion.
source <(ng completion script)
To customize prompt, run
p10k configure
or edit ~/.p10k.zsh.[[ ! -f ~/.p10k.zsh ]] || source ~/.p10k.zsh
zprof
The text was updated successfully, but these errors were encountered: