dotfiles/zsh/.zsh/prompt.zsh

16 lines
325 B
Bash
Raw Permalink Normal View History

2024-08-09 22:39:10 +02:00
PS1='%F{blue}%~ %(?.%F{green}.%F{red})%#%f '
source "$HOME/.zsh/vim-mode.zsh"
update_right_prompt () {
RPS1="%F{blue}-- $VI_KEYMAP --%f"
if [ ! -z "$GIT_BRANCH" ]; then
RPS1="%F{red} $GIT_BRANCH%f $RPS1"
fi
zle reset-prompt 2> /dev/null
}
update_right_prompt
source "$HOME/.zsh/git_branch.zsh"