disable git prompt if git completion is not sourced
This commit is contained in:
@@ -1,4 +1,8 @@
|
||||
|
||||
# display git status
|
||||
export GIT_PS1_SHOWDIRTYSTATE=1
|
||||
if [[ $(type -t foo) != function ]]; then
|
||||
__git_ps1(){
|
||||
}
|
||||
fi
|
||||
export PS1=' \[\e[0;32m\]\w\[\e[01;31m\]$(__git_ps1 "(%s)")\[\e[00m\]$ '
|
||||
|
||||
Reference in New Issue
Block a user