# HG changeset patch # User Mikael Berthe # Date 1687189508 -7200 # Node ID c8054d1073d35d54aa1f4725dc9407dd43373817 # Parent 4767c5a8b1f9bf0f0551d1d78e94dfd700d32436 zshrc_vcsinfo: Fix grep usage diff -r 4767c5a8b1f9 -r c8054d1073d3 misc/zshrc_vcsinfo --- a/misc/zshrc_vcsinfo Wed Nov 10 10:45:00 2021 +0100 +++ b/misc/zshrc_vcsinfo Mon Jun 19 17:45:08 2023 +0200 @@ -111,7 +111,7 @@ # If instead you want to show the marker only if there are untracked # files in $PWD, use: #[[ -n $(git ls-files --others --exclude-standard) ]] ; then - local nb_untracked=$(git status --porcelain | grep "\? \?" | wc -l) + local nb_untracked=$(git status --porcelain | grep "? ?" | wc -l) local nb_up=$(git status --porcelain | grep "M" | wc -l) hook_com[staged]+="%{${reset_color}%}$nb_untracked%{$fg[red]%}N %{${reset_color}%}$nb_up" fi