Merge pull request #525 from wendorf/master
Show git prompt when in a detached HEAD statepull/526/head
commit
e32dca1c35
|
|
@ -47,7 +47,7 @@ RBFU_THEME_PROMPT_SUFFIX='|'
|
||||||
function scm {
|
function scm {
|
||||||
if [[ "$SCM_CHECK" = false ]]; then SCM=$SCM_NONE
|
if [[ "$SCM_CHECK" = false ]]; then SCM=$SCM_NONE
|
||||||
elif [[ -f .git/HEAD ]]; then SCM=$SCM_GIT
|
elif [[ -f .git/HEAD ]]; then SCM=$SCM_GIT
|
||||||
elif which git &> /dev/null && [[ -n "$(git symbolic-ref HEAD 2> /dev/null)" ]]; then SCM=$SCM_GIT
|
elif which git &> /dev/null && [[ -n "$(git rev-parse 2> /dev/null)" ]]; then SCM=$SCM_GIT
|
||||||
elif [[ -d .hg ]]; then SCM=$SCM_HG
|
elif [[ -d .hg ]]; then SCM=$SCM_HG
|
||||||
elif which hg &> /dev/null && [[ -n "$(hg root 2> /dev/null)" ]]; then SCM=$SCM_HG
|
elif which hg &> /dev/null && [[ -n "$(hg root 2> /dev/null)" ]]; then SCM=$SCM_HG
|
||||||
elif [[ -d .svn ]]; then SCM=$SCM_SVN
|
elif [[ -d .svn ]]; then SCM=$SCM_SVN
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue