my nixos dotfiles :3 (git.koi.rip mirror) git.koi.rip/koi/dotfiles
linux dotfiles neovim nixos catppuccin

zsh: strip `heads/` from branch names in prompt

+6
+6
external/zsh/prompt.zsh
··· 14 14 local reset=$'\e[0m' 15 15 local newline=$'\n' 16 16 17 + 18 + zstyle ':vcs_info:git*' hooks git-strip-heads 19 + function +vi-git-strip-heads() { 20 + hook_com[branch]=${hook_com[branch]#heads/} 21 + } 22 + 17 23 zstyle ':vcs_info:*' formats "${dim}%s( ${accent}%b${reset}${dim} )" 18 24 zstyle ':vcs_info:*' actionformats "${dim}%s( ${accent}%b${reset} | ${accent}%a${reset}${dim} )" 19 25 zstyle ':vcs_info:*' enable git