about summary refs log tree commit diff
path: root/Completion/Zsh/Command/_which
diff options
context:
space:
mode:
Diffstat (limited to 'Completion/Zsh/Command/_which')
-rw-r--r--Completion/Zsh/Command/_which7
1 files changed, 4 insertions, 3 deletions
diff --git a/Completion/Zsh/Command/_which b/Completion/Zsh/Command/_which
index c43704ae8..9b789c86b 100644
--- a/Completion/Zsh/Command/_which
+++ b/Completion/Zsh/Command/_which
@@ -1,6 +1,6 @@
 #compdef which whence where type
 
-local farg aarg cargs args state line curcontext="$curcontext" ret=1
+local farg aarg xarg cargs args state line curcontext="$curcontext" ret=1
 
 cargs=( \
   '(-v -c)-w[print command type]' \
@@ -11,6 +11,7 @@ cargs=( \
   '*:commands:->command' )
 farg='-f[output contents of functions]'
 aarg='-a[print all occurrences in path]'
+xarg='-x+[specify spaces to use for indentation in function expansion]:spaces'
 
 case ${service} in
   whence)
@@ -19,8 +20,8 @@ case ${service} in
       '(-v -w)-c[csh-like output]' \
       "${cargs[@]}" "$farg" "$aarg" && ret=0
   ;;
-  where) _arguments -C -s -A "-*" -S "${cargs[@]}" && ret=0;;
-  which) _arguments -C -s -A "-*" -S "${cargs[@]}" "$aarg" && ret=0;;
+  where) _arguments -C -s -A "-*" -S "${cargs[@]}" "$xarg" && ret=0;;
+  which) _arguments -C -s -A "-*" -S "${cargs[@]}" "$aarg" "$xarg" && ret=0;;
   type) _arguments -C -s -A "-*" -S "${cargs[@]}" "$aarg" "$farg" && ret=0;;
 esac