6 lines
215 B
Bash
6 lines
215 B
Bash
parse_git_branch() {
|
|
git symbolic-ref --short HEAD 2> /dev/null | sed -E 's/(.+)/ [\1]/g'
|
|
}
|
|
|
|
PROMPT='%B%F{magenta}%m%F{none}%b:%B%F{cyan}%2~%F{none}%b%F{yellow}$(parse_git_branch) %F{%(?.green.red)}%#%F{none} '
|