Skip to content

A Git PS1 prompt that gives information about the repository's status and current branch.

Notifications You must be signed in to change notification settings

flowbehappy/git-colored-ps1

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 
 
 

Repository files navigation

Git Colored PS1

This is Bash source for a Git prompt that shows you the status of your git repository every time you see the prompt.

  • green = staged changes
  • red = unstaged changes
  • gray = untracked files

Example

Example shell session

I've found this to be invaluable when working with Git, since you don't have to type git status (or gs for those that made the alias) so often, and don't have to spend the time reading through the output.

Installation

Either source git-ps1.sh from your .bashrc or copy and paste the contents.

(appended to .bashrc)

source /<path>/git-ps1.sh

About

A Git PS1 prompt that gives information about the repository's status and current branch.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Shell 100.0%