From 6d930a94890ac8c6cffaa884eec5458316f44be9 Mon Sep 17 00:00:00 2001 From: Andre Noll Date: Sun, 5 Nov 2017 19:38:44 +0100 Subject: [PATCH] bash_completion: Get rid of weird retry logic. It's totally unclear what this is supposed to do, as the commit which introduced it six years ago does not say anything about the space character being the only "proper" value. Removing the check fixes an issue that only happens on the first completion attempt: if a unique completion is possible, the completer prints this completion as if there were multiple completions possible instead of completing the command line. --- bash_completion | 4 ---- 1 file changed, 4 deletions(-) diff --git a/bash_completion b/bash_completion index 0eb7074c..3dd25e5a 100644 --- a/bash_completion +++ b/bash_completion @@ -9,10 +9,6 @@ _para_complete() local line="$COMP_LINE" OLD_IFS="$IFS" local opts n - if [[ "$COMP_WORDBREAKS" != ' ' ]]; then - COMP_WORDBREAKS=' ' - return 124 # try again with proper value - fi # This extracts short and long options from the help output local script='{ if ($1 ~ "-[a-zA-Z]," && $2 ~ "--[a-zA-Z]") { -- 2.39.5