Files
dotfiles/bash/.bashrc.d/git.bash
T
2026-06-26 20:50:35 -04:00

14 lines
508 B
Bash

# Git + Colorful Prompt
if [ -f "/usr/share/git/completion/git-prompt.sh" ]; then
source /usr/share/git/completion/git-prompt.sh
export GIT_PS1_SHOWDIRTYSTATE=1
export GIT_PS1_SHOWSTASHSTATE=1
export GIT_PS1_SHOWUNTRACKEDFILES=1
export GIT_PS1_SHOWUPSTREAM="auto"
# Bright green user@host (what you liked)
PS1='\[\e[1;38;5;46m\]\u@\h\[\e[0m\] \[\e[38;5;51m\]\w\[\e[0m\]\[\e[90m\]$(__git_ps1 " (%s)")\[\e[0m\] \$ '
else
PS1='\[\e[1;38;5;46m\]\u@\h\[\e[0m\] \[\e[38;5;51m\]\w\[\e[0m\] \$ '
fi