From 2678595902815b848c0abdd2dff95524da47de4b Mon Sep 17 00:00:00 2001 From: ray Date: Tue, 30 Sep 2025 20:32:56 +0100 Subject: [PATCH] update prompt colors for branch name visibility Rearranged color assignments for improved clarity in the git status prompt, ensuring the branch name is highlighted in bright green for better visibility. --- gitstatus-custom.sh | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/gitstatus-custom.sh b/gitstatus-custom.sh index 2a3a66f..0ec92fc 100644 --- a/gitstatus-custom.sh +++ b/gitstatus-custom.sh @@ -13,8 +13,9 @@ function my_gitstatus_prompt_update() { [[ "$VCS_STATUS_RESULT" == ok-sync ]] || return 0 # not a git repo local reset=$'\001\e[0m\002' # no color - local bright_white=$'\001\e[1;37m\002' # bright white - branch name and modified/untracked - local red=$'\001\e[38;5;196m\002' # red - urgent attention (conflicts, merge) + local bright_green=$'\001\e[01;32m\002' # bright green - branch name (matches hostname) + local bright_white=$'\001\e[1;37m\002' # bright white - modified/untracked + local red=$'\001\e[38;5;196m\002' # red - urgent attention (conflicts, merge) local p @@ -32,7 +33,7 @@ function my_gitstatus_prompt_update() { # Truncate long branch names and tags (( ${#where} > 32 )) && where="${where:0:12}…${where: -12}" - p+="${bright_white}${where}" + p+="${bright_green}${where}" # Remote tracking status (no color - less distracting) (( VCS_STATUS_COMMITS_BEHIND )) && p+=" ${reset}behind:${VCS_STATUS_COMMITS_BEHIND}"