about summary refs log tree commit diff
path: root/Completion/Core/_expand
diff options
context:
space:
mode:
Diffstat (limited to 'Completion/Core/_expand')
-rw-r--r--Completion/Core/_expand8
1 files changed, 8 insertions, 0 deletions
diff --git a/Completion/Core/_expand b/Completion/Core/_expand
index 0b8083845..5018a6871 100644
--- a/Completion/Core/_expand
+++ b/Completion/Core/_expand
@@ -58,6 +58,14 @@
 
 local exp word="$PREFIX$SUFFIX" group=-V expl expl2 disp
 
+# First, see if we should insert all *completions*.
+
+if [[ -n "$compconfig[expand_completions]" &&
+      "${(e):-\$[$compconfig[expand_substitute]]}" -eq 1 ]]; then
+  compstate[insert]=all
+  return 1
+fi
+
 # Do this only for the first global matcher.
 
 [[ "$compstate[matcher]" -le 1 ]] || return 1