From fe4504cef92440f36b7fdcad9be6e7365bd89878 Mon Sep 17 00:00:00 2001 From: Robin Ramael Date: Fri, 11 Feb 2011 09:09:00 +0100 Subject: [PATCH] Fixed bug in git scm plugin where the prompt info would not be displayed in subdirs. --- scm/git.scm.zsh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/scm/git.scm.zsh b/scm/git.scm.zsh index 095f36012..f3af909a2 100644 --- a/scm/git.scm.zsh +++ b/scm/git.scm.zsh @@ -1,5 +1,5 @@ function scm_in_git_repo () { - if [[ -d .git ]]; then + if [ "$(git st 2>/dev/null)" ]; then echo 1 fi } @@ -19,4 +19,4 @@ scm_parse_git_dirty () { else echo "$ZSH_THEME_SCM_PROMPT_CLEAN" fi -} \ No newline at end of file +}