Update apple.zsh-theme

I changed the original purple logo to black and white alternating, which changes according to light and dark, making it more eye-catching
This commit is contained in:
Hallehack 2025-06-02 22:17:17 +08:00 committed by GitHub
commit c09682ac64
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -1,16 +1,16 @@
function toon {
echo -n ""
echo -n "%B%f" # 使用默认前景色
}
autoload -Uz vcs_info
zstyle ':vcs_info:*' check-for-changes true
zstyle ':vcs_info:*' unstagedstr '%F{red}*' # display this when there are unstaged changes
zstyle ':vcs_info:*' stagedstr '%F{yellow}+' # display this when there are staged changes
zstyle ':vcs_info:*' actionformats '%F{5}[%F{2}%b%F{3}|%F{1}%a%c%u%F{5}]%f '
zstyle ':vcs_info:*' formats '%F{5}[%F{2}%b%c%u%F{5}]%f '
zstyle ':vcs_info:*' unstagedstr '%F{red}*'
zstyle ':vcs_info:*' stagedstr '%F{yellow}+'
zstyle ':vcs_info:*' actionformats '%F{8}[%F{2}%b%F{3}|%F{1}%a%c%u%F{8}]%f '
zstyle ':vcs_info:*' formats '%F{8}[%F{2}%b%c%u%F{8}]%f '
zstyle ':vcs_info:svn:*' branchformat '%b'
zstyle ':vcs_info:svn:*' actionformats '%F{5}[%F{2}%b%F{1}:%F{3}%i%F{3}|%F{1}%a%c%u%F{5}]%f '
zstyle ':vcs_info:svn:*' formats '%F{5}[%F{2}%b%F{1}:%F{3}%i%c%u%F{5}]%f '
zstyle ':vcs_info:svn:*' actionformats '%F{8}[%F{2}%b%F{1}:%F{3}%i%F{3}|%F{1}%a%c%u%F{8}]%f '
zstyle ':vcs_info:svn:*' formats '%F{8}[%F{2}%b%F{1}:%F{3}%i%c%u%F{8}]%f '
zstyle ':vcs_info:*' enable git cvs svn
theme_precmd () {
@ -18,7 +18,8 @@ theme_precmd () {
}
setopt prompt_subst
PROMPT='%{$fg[magenta]%}$(toon)%{$reset_color%} %~/ %{$reset_color%}${vcs_info_msg_0_}%{$reset_color%}'
# 使用默认前景色(:和苹果图标),保持粗体效果
PROMPT='%B%f: $(toon)%b %~ ${vcs_info_msg_0_}%f'
autoload -U add-zsh-hook
add-zsh-hook precmd theme_precmd