From 5b6855e3eb98e0016a508a25aae61e29281e4e4d Mon Sep 17 00:00:00 2001 From: Colin Hebert Date: Wed, 11 Apr 2012 19:21:46 +0100 Subject: [PATCH] Always format Git dirty --- modules/git/functions/git-info | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/modules/git/functions/git-info b/modules/git/functions/git-info index df7b29c2..c344189b 100644 --- a/modules/git/functions/git-info +++ b/modules/git/functions/git-info @@ -29,7 +29,7 @@ # zstyle ':omz:module:git' deleted 'deleted:%d' # # # %D - Indicator to notify of dirty files. -# zstyle ':omz:module:git' dirty 'dirty:%D' +# zstyle ':omz:module:git' dirty '%(D.clean.dirty:%D)' # # # %m - Indicator to notify of modified files. # zstyle ':omz:module:git' modified 'modified:%m' @@ -376,10 +376,8 @@ function git-info { fi # Format dirty. - if (( $dirty > 0 )); then - zstyle -s ':omz:module:git' dirty 'dirty_format' - zformat -f dirty_formatted "$dirty_format" "D:$dirty" - fi + zstyle -s ':omz:module:git' dirty 'dirty_format' + zformat -f dirty_formatted "$dirty_format" "D:$dirty" # Format info. zstyle -a ':omz:module:git' info 'info_formats'