git-augmented PS1 for BASH
Pull request Compare This branch is 5 commits ahead, 73 commits behind mikegerwitz:master.
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Failed to load latest commit information.


git-ps1 - git-augmented PS1 for BASH

To use, modify your PS1 variable (e.g. in ~/.bashrc) to include the script:
  PS1="$PS1\$($( cat ))"

This script produces output in a number of different colors. To ensure the
prompt operates correctly, non-printable characters must be escaped (\[\]).
However, these characters are not recognized when output from an external
script. Therefore, the script must be inserted directly into the PS1 string,
where echoing the escape sequence will produce the intended result.

All configuration is done via GITPS1_* environment variables.

Indicators (set to '0' to disable)
  GITPS1_IND_STAGED      - Staged changes
  GITPS1_IND_UNSTAGED    - Unstaged changes
  GITPS1_IND_UNTRACKED   - Untracked files
  GITPS1_IND_AHEAD       - Ahead of tracking branch
  GITPS1_IND_AHEAD_COUNT - Whether to display number of commits ahead (e.g. @5)

  GITPS1_COLOR_DEFAULT   - Default color, used to display brackets and branch
  GITPS1_COLOR_FASTFWD   - Color used for fast-forward indicator and used to
                           display brackets and hash when not on a branch
  GITPS1_COLOR_STAGED    - Color used to for staged changes indicator
  GITPS1_COLOR_UNTRACKED - Color used for untracked files indicator
  GITPS1_COLOR_UNSTAGED  - Color used for unstaged changes indicator
  GITPS1_COLOR_AHEAD     - Color used for ahead indicator (ahead of tracking)