summaryrefslogtreecommitdiff
path: root/Completion/Zsh
diff options
context:
space:
mode:
Diffstat (limited to 'Completion/Zsh')
-rw-r--r--Completion/Zsh/Command/_alias15
-rw-r--r--Completion/Zsh/Context/_value5
2 files changed, 19 insertions, 1 deletions
diff --git a/Completion/Zsh/Command/_alias b/Completion/Zsh/Command/_alias
index 98ae94046..ecc298c73 100644
--- a/Completion/Zsh/Command/_alias
+++ b/Completion/Zsh/Command/_alias
@@ -1,8 +1,21 @@
#compdef alias
+local curcontext="$curcontext" state line suf
+
_arguments -C -s -A "-*" -S \
'-+g[list or define global aliases]' \
'-+r[list or define regular aliases]' \
'-+m[print aliases matching specified pattern]' \
'-L[print each alias in the form of calls to alias]' \
- '*::alias definition:_aliases -S ='
+ '*::alias definition:->defn'
+
+if [[ -n "$state" ]]; then
+ if compset -P 1 '*='; then
+ compset -q
+ _normal
+ else
+ compset -S '=*' || suf='='
+ _wanted alias expl 'alias definition' _aliases -S "$suf"
+ fi
+fi
+
diff --git a/Completion/Zsh/Context/_value b/Completion/Zsh/Context/_value
index 78e929316..6ee8f4235 100644
--- a/Completion/Zsh/Context/_value
+++ b/Completion/Zsh/Context/_value
@@ -60,6 +60,11 @@ _value:LDFLAGS () {
_value:DISPLAY() { _x_display "$@" }
+_value:PRINTER() { _printers "$@" }
+_value:LPDEST() { _printers "$@" }
+
+_value:TERM() { _terminals "$@" }
+
_value:TZ() { _time_zone "$@" }
_value "$@"