Compare commits

...

4 Commits

Author SHA1 Message Date
Max Kovgan e5c3ffe852
Merge 1af0fedcf0 into 6e7ac0544e 2025-02-20 06:29:02 +01:00
tuzi3040 6e7ac0544e
fix(agnoster): print white text over black for light theme only (#12983) 2025-02-19 12:37:18 +01:00
Adrien Plazas 92da3108b5
fix(agnoster): print white text over black (#12525) 2025-02-14 10:18:01 +01:00
Maxim Kovgan 1af0fedcf0 virtualenvwrapper plugin fix #112852
when we're not in enabled mode and `DISABLE_VENV_CD=1`:
  - safely delete the chpwd hook `workon_cwd` if it were previously set up

Signed-off-by: Maxim Kovgan <makovgan@redhat.com>
2024-12-18 09:27:53 +02:00
2 changed files with 16 additions and 4 deletions

View File

@ -89,4 +89,9 @@ if [[ ! $DISABLE_VENV_CD -eq 1 ]]; then
autoload -U add-zsh-hook
add-zsh-hook chpwd workon_cwd
[[ $PWD != ~ ]] && workon_cwd
else
if [[ "${chpwd_functions[(Ie)workon_cwd]}" -ne 0 ]]; then
autoload -U add-zsh-hook
add-zsh-hook -d chpwd workon_cwd
fi
fi

View File

@ -35,8 +35,14 @@
CURRENT_BG='NONE'
case ${SOLARIZED_THEME:-dark} in
light) CURRENT_FG='white';;
*) CURRENT_FG='black';;
light)
CURRENT_FG='white'
CURRENT_DEFAULT_FG='white'
;;
*)
CURRENT_FG='black'
CURRENT_DEFAULT_FG='default'
;;
esac
### Theme Configuration Initialization
@ -48,7 +54,7 @@ esac
: ${AGNOSTER_DIR_BG:=blue}
# user@host
: ${AGNOSTER_CONTEXT_FG:=default}
: ${AGNOSTER_CONTEXT_FG:=${CURRENT_DEFAULT_FG}}
: ${AGNOSTER_CONTEXT_BG:=black}
# Git related
@ -85,6 +91,7 @@ esac
: ${AGNOSTER_STATUS_RETVAL_FG:=red}
: ${AGNOSTER_STATUS_ROOT_FG:=yellow}
: ${AGNOSTER_STATUS_JOB_FG:=cyan}
: ${AGNOSTER_STATUS_FG:=${CURRENT_DEFAULT_FG}}
: ${AGNOSTER_STATUS_BG:=black}
## Non-Color settings - set to 'true' to enable
@ -327,7 +334,7 @@ prompt_status() {
[[ $UID -eq 0 ]] && symbols+="%{%F{$AGNOSTER_STATUS_ROOT_FG}%}⚡"
[[ $(jobs -l | wc -l) -gt 0 ]] && symbols+="%{%F{$AGNOSTER_STATUS_JOB_FG}%}⚙"
[[ -n "$symbols" ]] && prompt_segment "$AGNOSTER_STATUS_BG" default "$symbols"
[[ -n "$symbols" ]] && prompt_segment "$AGNOSTER_STATUS_BG" "$AGNOSTER_STATUS_FG" "$symbols"
}
#AWS Profile: