From 215442575b148c7abb1677d25c1283606ff974bf Mon Sep 17 00:00:00 2001 From: Jonny Barnes Date: Fri, 20 Sep 2024 21:18:21 +0100 Subject: [PATCH] Show Loading message in right prompt --- zshrc.zsh | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/zshrc.zsh b/zshrc.zsh index c4c6bad..a1899df 100644 --- a/zshrc.zsh +++ b/zshrc.zsh @@ -142,8 +142,11 @@ zstyle ':vcs_info:git*' stagedstr '+' # but can be slow on large repos zstyle ':vcs_info:*:*' check-for-changes true -# Set the right prompt to the vcs_info message -RPROMPT='%F{8}${vcs_info_msg_0_}' +# First show the Loading indicator in the right prompt if shell plugins are still loading +RPROMPT='%F{8}$(if [[ -n $SHELL_LOADING ]]; then echo "Loading... "; fi)' + +# Then we can also show the git branch +RPROMPT+='${vcs_info_msg_0_}' # First set a dot that changes colour on success/fail or previous command PROMPT='%(?.%F{blue}⏺.%F{red}⏺)%f '