From d0b52f1d4e43def141e272238cd01cf2569c1fe6 Mon Sep 17 00:00:00 2001 From: Daniel Lynn Date: Thu, 5 Aug 2021 13:56:03 -0500 Subject: [PATCH] Cleanup; add zoxide --- zshrc | 24 +++++++++++++++++++----- 1 file changed, 19 insertions(+), 5 deletions(-) diff --git a/zshrc b/zshrc index ccadf9c..6008d0d 100644 --- a/zshrc +++ b/zshrc @@ -23,15 +23,29 @@ else source /usr/share/zsh/manjaro-zsh-prompt fi - [[ -s ~/.p10k.zsh ]] && source ~/.p10k.zsh + if [[ -s ~/.p10k.zsh ]]; then + source ~/.p10k.zsh + fi +fi + +if [[ -n "$(command -v zoxide)" ]]; then + eval "$(zoxide init zsh)" fi # Custom aliases -[[ -s ~/.aliases ]] && source ~/.aliases +if [[ -s ~/.aliases ]]; then + source ~/.aliases; +fi # NVM -[[ -s "$NVM_DIR/nvm.sh" ]] && source "$NVM_DIR/nvm.sh" # This loads nvm -[[ -s "$NVM_DIR/bash_completion" ]] && \. "$NVM_DIR/bash_completion" # This loads nvm bash_completion +if [[ -s "$NVM_DIR/nvm.sh" ]]; then + source "$NVM_DIR/nvm.sh" # This loads nvm +fi +if [[ -s "$NVM_DIR/bash_completion" ]]; then + source "$NVM_DIR/bash_completion" # This loads nvm bash_completion +fi # Source machine-specific setup -[[ -s ~/.zshrc.local ]] && source ~/.zshrc.local +if [[ -s ~/.zshrc.local ]]; then + source ~/.zshrc.local; +fi