diff mbox series

[v2,11/26] completion: bash: simplify equal suffix check

Message ID 20201110212136.870769-12-felipe.contreras@gmail.com (mailing list archive)
State New, archived
Headers show
Series completion: bash: a bunch of fixes, cleanups, and reorganization | expand

Commit Message

Felipe Contreras Nov. 10, 2020, 9:21 p.m. UTC
We know the prefix is already '--no-', there's no need to check for the
first '--'.

Signed-off-by: Felipe Contreras <felipe.contreras@gmail.com>
---
 contrib/completion/git-completion.bash | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
diff mbox series

Patch

diff --git a/contrib/completion/git-completion.bash b/contrib/completion/git-completion.bash
index bb1250f10c..3f684cfe59 100644
--- a/contrib/completion/git-completion.bash
+++ b/contrib/completion/git-completion.bash
@@ -335,7 +335,7 @@  __gitcomp ()
 			c="$c${4-}"
 			if [[ $c == "$cur_"* ]]; then
 				case $c in
-				--*=|*.) ;;
+				*=|*.) ;;
 				*) c="$c " ;;
 				esac
 				COMPREPLY[i++]="${2-}$c"