From 09f5ee1da84eb3d48ca7723faa42d3c29d94da08 Mon Sep 17 00:00:00 2001 From: Alexander Sulfrian Date: Tue, 23 Jun 2009 05:14:23 +0200 Subject: fix git magic in prompt to not activate in .git dir or bare repositories --- bashrc/common/prompt.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/bashrc/common/prompt.sh b/bashrc/common/prompt.sh index f0eb9c8..a2b98a4 100644 --- a/bashrc/common/prompt.sh +++ b/bashrc/common/prompt.sh @@ -47,7 +47,7 @@ ps_scm_f() { s="$(color yellow)r$r$(color red)$(svn status | grep -q -v '^?' && echo -n "*" )" else local d=$(git rev-parse --git-dir 2>/dev/null ) b= r= a= - if [[ -n "${d}" && ! -f "${d}/../.promptignore" ]] ; then + if [[ -n "${d}" && "${d}" != "." && ! -f "${d}/../.promptignore" ]] ; then if [[ -d "${d}/../.dotest" ]] ; then if [[ -f "${d}/../.dotest/rebase" ]] ; then r="rebase" -- cgit v1.2.3