completion: Fix GIT_PS1_SHOWDIRTYSTATE to prevent unbound variable errors.

Signed-off-by: Ted Pavlic <ted@tedpavlic.com>
Acked-by: Shawn O. Pearce <spearce@spearce.org>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
This commit is contained in:
Ted Pavlic 2009-02-06 11:05:37 -05:00 committed by Junio C Hamano
parent ffe4da1573
commit cf9957875c

View File

@ -125,7 +125,7 @@ __git_ps1 ()
local w local w
local i local i
if test -n "$GIT_PS1_SHOWDIRTYSTATE"; then if test -n "${GIT_PS1_SHOWDIRTYSTATE-}"; then
if test "$(git config --bool bash.showDirtyState)" != "false"; then if test "$(git config --bool bash.showDirtyState)" != "false"; then
git diff --no-ext-diff --ignore-submodules \ git diff --no-ext-diff --ignore-submodules \
--quiet --exit-code || w="*" --quiet --exit-code || w="*"