Skip to content

Latest commit

 

History

History
33 lines (23 loc) · 893 Bytes

README.md

File metadata and controls

33 lines (23 loc) · 893 Bytes

git-prompt

Adds some basic git status to the bash prompt, mimics the github display of ahead/behind.

Screenshots

Ahead and behind, yellow indicates uncomitted changes.

Alt text

Ahead, red color = untracked files.

Alt text

Up to date, with one stash. Green color means working directory clean.

Alt text

Try it out

By simply pasting this in your terminal:

source <(curl https://raw.github.com/jseb/git-prompt/master/git-prompt) \
	&& export PS1="\$(git_prompt)"$PS1

Installation

Clone the repo (or just download the file), and add this to the end of your .bash_profile:

source path/to/git-prompt/git-prompt
export PS1="\$(git_prompt)"$PS1