diff --git a/zshrc b/zshrc index 4cbdc20..039b5cf 100644 --- a/zshrc +++ b/zshrc @@ -14,24 +14,39 @@ USE_POWERLINE="true" if [[ -e /usr/share/zsh/manjaro-zsh-config ]]; then source /usr/share/zsh/manjaro-zsh-config fi -# Use manjaro zsh prompt -if [[ -e /usr/share/zsh/manjaro-zsh-prompt ]]; then - source /usr/share/zsh/manjaro-zsh-prompt -fi -# To customize prompt, run `p10k configure` or edit ~/.p10k.zsh. +# Use a prompt, depending on what is available: +# 1. starship +# 2. p10k +# 3. manjaro if [[ -n "$(command -v starship)" ]]; then eval "$(starship init zsh)" else if [[ -s ~/.p10k.zsh ]]; then source ~/.p10k.zsh + else + # Use manjaro zsh prompt + if [[ -e /usr/share/zsh/manjaro-zsh-prompt ]]; then + source /usr/share/zsh/manjaro-zsh-prompt + fi fi fi +# Autosuggestions +if [[ -s /usr/share/zsh/plugins/zsh-autosuggestions/zsh-autosuggestions.zsh ]]; then + source /usr/share/zsh/plugins/zsh-autosuggestions/zsh-autosuggestions.zsh +fi + +# Intelligent and fast autojump if [[ -n "$(command -v zoxide)" ]]; then eval "$(zoxide init zsh)" fi +# Cheat my way through the CLI +if [[ -n "$(command -v navi)" ]]; then + eval "$(navi widget zsh)" +fi + # Custom aliases if [[ -s ~/.aliases ]]; then source ~/.aliases