Skip to content

Instantly share code, notes, and snippets.

@pak11273
Created February 4, 2021 19:16
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save pak11273/c42c0fa035b3418c6163ba9c6de3d8c6 to your computer and use it in GitHub Desktop.
Save pak11273/c42c0fa035b3418c6163ba9c6de3d8c6 to your computer and use it in GitHub Desktop.
.git_profile
# Add these lines to the bottom of your .bash_profile
# Enable tab completion
source ~/git-completion.bash
# colors!
green="\[\033[0;32m\]"
blue="\[\033[0;34m\]"
purple="\[\033[0;35m\]"
reset="\[\033[0m\]"
# Change command prompt
source ~/git-prompt.sh
export GIT_PS1_SHOWDIRTYSTATE=1
# '\u' adds the name of the current user to the prompt
# '\$(__git_ps1)' adds git-related stuff
# '\W' adds the name of the current directory
export PS1="$purple\u$green\$(__git_ps1)$blue \W $ $reset"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment