diff options
Diffstat (limited to 'Completion')
-rw-r--r-- | Completion/Commands/_complete_debug | 3 | ||||
-rw-r--r-- | Completion/Core/_main_complete | 6 | ||||
-rw-r--r-- | Completion/Core/_setup | 2 |
3 files changed, 6 insertions, 5 deletions
diff --git a/Completion/Commands/_complete_debug b/Completion/Commands/_complete_debug index a876839c0..4f0ce7f27 100644 --- a/Completion/Commands/_complete_debug +++ b/Completion/Commands/_complete_debug @@ -20,7 +20,8 @@ unsetopt xtrace [[ -t 3 ]] && { print -sR "${VISUAL:-${EDITOR:-${PAGER:-more}}} $tmp ;: $w" _message -r "Trace output left in $tmp (up-history to view)" - compstate[list]='list force' + [[ $compstate[nmatches] -le 1 && $compstate[list] != *force* ]] && + compstate[list]='list force messages' exec 2>&3 3>&- } diff --git a/Completion/Core/_main_complete b/Completion/Core/_main_complete index a9a1d2a9a..39c8f0e5e 100644 --- a/Completion/Core/_main_complete +++ b/Completion/Core/_main_complete @@ -220,9 +220,9 @@ if [[ $compstate[old_list] = keep || nm -gt 1 ]]; then fi fi fi -elif [[ nm -eq 0 && -n "$_comp_mesg" ]]; then +elif [[ nm -le 1 && -n "$_comp_mesg" ]]; then compstate[insert]='' - compstate[list]='list force' + compstate[list]='list force messages' elif [[ nm -eq 0 && $#_lastdescr -ne 0 && $compstate[old_list] != keep ]] && zstyle -s ":completion:${curcontext}:warnings" format format; then @@ -251,7 +251,7 @@ fi [[ "$_comp_force_list" = always || ( "$_comp_force_list" = ?* && nm -ge _comp_force_list ) ]] && - compstate[list]="$compstate[list] force" + compstate[list]="${compstate[list]//messages} force" [[ "$compstate[old_list]" = keep ]] && ZLS_COLORS="$_saved_colors" diff --git a/Completion/Core/_setup b/Completion/Core/_setup index 6d5f09ab3..6bc36e3ef 100644 --- a/Completion/Core/_setup +++ b/Completion/Core/_setup @@ -64,5 +64,5 @@ fi zstyle -s ":completion:${curcontext}:$1" force-list val && [[ "$val" = always || ( "$val" = [0-9]## && - ( -z "$_comp_force_list" || _comp_force_list -lt val ) ) ]] && + ( -z "$_comp_force_list" || _comp_force_list -gt val ) ) ]] && _comp_force_list="$val" |