Search code examples
gitshellzshpromptoh-my-zsh

In an Oh My Zsh customized prompt, what is the number with the white background?


I'm using Oh My Zsh on macOS and, while working in a Git-versioned directory, I have three different information fields in the prompt:

  1. the current folder [blue background]
  2. the local branch (+ahead/-behind) [green background], and
  3. the remote branch (+ahead/-behind) [teal background]

It usually works just fine, except that now I have an additional section, the part with the white backgroud: Oh My ZSH custom prompt

I tried running git status to understand what that "+9" could possibly mean:

On branch bootstrap-adjustments Your branch is up-to-date with 'origin/bootstrap-adjustments'. nothing to commit, working tree clean

I also tried looking into the git-prompt plugin source code but I wasn't able to find that section.

Does anyone know what that "+9" means?


Solution

  • Thanks to A fellow Vimer on Twitter:

    The +9 is the number of stashes in the repo.

    Found out by running: git stash list.