Improve colors for branch display in bash git prompt

This commit is contained in:
Talia 2018-11-19 21:33:37 +01:00
parent e5e62e6044
commit 87a6485177
1 changed files with 5 additions and 2 deletions

7
bashrc
View File

@ -55,9 +55,12 @@ git__prompt () {
fi fi
if [ $branch = 'master' ] if [ $branch = 'master' ]
then then
echo -ne " \033[01;34m$branch" echo -ne " $blue$branch"
elif [ ${branch:0:1} = '#' ]
then
echo -ne " $red$branch"
else else
echo -ne " \033[01;32m$branch" echo -ne " $yellow$branch"
fi fi
if [ $modif = 0 ] if [ $modif = 0 ]