1
0
Fork 0
mirror of https://github.com/git/git.git synced 2024-06-09 22:16:14 +02:00

completion: bash: trivial cleanup

There's no need to set a variable we are not going to use.

Signed-off-by: Felipe Contreras <felipe.contreras@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
This commit is contained in:
Felipe Contreras 2020-10-27 20:07:09 -06:00 committed by Junio C Hamano
parent 35a4170d86
commit 5a364d2a18

View File

@ -416,14 +416,13 @@ __gitcomp_builtin ()
local options
eval "options=\${$var-}"
local completion_helper
if [ "$GIT_COMPLETION_SHOW_ALL" = "1" ]; then
completion_helper="--git-completion-helper-all"
else
completion_helper="--git-completion-helper"
fi
if [ -z "$options" ]; then
local completion_helper
if [ "$GIT_COMPLETION_SHOW_ALL" = "1" ]; then
completion_helper="--git-completion-helper-all"
else
completion_helper="--git-completion-helper"
fi
# leading and trailing spaces are significant to make
# option removal work correctly.
options=" $incl $(__git ${cmd/_/ } $completion_helper) " || return