From 4a7392fdd0be8fafcaffccc206f23c7746129fb8 Mon Sep 17 00:00:00 2001 From: Adam Lindberg Date: Tue, 7 Jun 2011 15:40:32 +0200 Subject: [PATCH] Fix git R and M status when used together --- themes/guru.zsh-theme | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/themes/guru.zsh-theme b/themes/guru.zsh-theme index a5ffdb722..dfec3dfb5 100644 --- a/themes/guru.zsh-theme +++ b/themes/guru.zsh-theme @@ -35,7 +35,7 @@ custom_git_prompt_status() { if $(echo "$INDEX" | grep '^ D ' &> /dev/null); then STATUS="$ZSH_THEME_GIT_PROMPT_DELETED$STATUS" fi - if $(echo "$INDEX" | grep '^ M ' &> /dev/null); then + if $(echo "$INDEX" | grep '^.M ' &> /dev/null); then STATUS="$ZSH_THEME_GIT_PROMPT_MODIFIED$STATUS" elif $(echo "$INDEX" | grep '^AM ' &> /dev/null); then STATUS="$ZSH_THEME_GIT_PROMPT_MODIFIED$STATUS" @@ -46,7 +46,7 @@ custom_git_prompt_status() { if $(echo "$INDEX" | grep '^D ' &> /dev/null); then STATUS="$ZSH_THEME_GIT_PROMPT_STAGED_DELETED$STATUS" fi - if $(echo "$INDEX" | grep '^R ' &> /dev/null); then + if $(echo "$INDEX" | grep '^R' &> /dev/null); then STATUS="$ZSH_THEME_GIT_PROMPT_STAGED_RENAMED$STATUS" fi if $(echo "$INDEX" | grep '^M ' &> /dev/null); then