Skip to content

Instantly share code, notes, and snippets.

Created October 14, 2022 11:56
  • Star 1 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
Star You must be signed in to star a gist
What would you like to do?
# Load git info module
autoload -Uz vcs_info
# Configure git info
local fmt_vcs_status='%F{yellow}‹%b%f%u%c%F{yellow}›%f'
zstyle ':vcs_info:*' enable git
zstyle ':vcs_info:git:*' check-for-changes true
zstyle ':vcs_info:git:*' unstagedstr '%F{red}●%f'
zstyle ':vcs_info:git:*' stagedstr '%F{green}+%f'
zstyle ':vcs_info:git:*' patch-format ' %p %n/%a'
zstyle ':vcs_info:git:*' actionformats "${fmt_vcs_status} [%a%m]"
zstyle ':vcs_info:git:*' formats "${fmt_vcs_status}"
precmd() { vcs_info }
prompt_likebira_setup() {
# Prompt (inspired by Oh my ZSHs Bira theme)
local return_code='%(?..%F{red}%? ↵%f)'
local user_host='%B%(!.%F{red}.%F{green})%n@%m%f%b '
local user_symbol='%(!.#.$)'
local current_dir='%B%F{blue}%~ %f%b'
setopt prompt_subst
╰─%B%#%b '
# Add the theme to promptsys
prompt_themes+=( likebira )
# Load the theme
prompt likebira
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment