[fish] detect simultaneously unstaged and staged files in git prompt

This commit is contained in:
lhark 2019-03-09 11:47:10 -05:00
parent b53eb9327b
commit cf6ad12834

View file

@ -56,7 +56,7 @@ function __plaid_git_prompt --description 'Write out the git prompt'
if echo $i | grep '^[AMRCD]' >/dev/null
set -a gs staged
end
if echo $i | grep '^ [AMRCD]' >/dev/null
if echo $i | grep '^.\?[AMRCD]' >/dev/null
set -a gs unstaged
end
if echo $i | grep '^??' >/dev/null