blob: 44512f64800d983875857bf32af0a70d8e9ad8df (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
|
#autoload
local format raw
if [[ "$1" = -e ]]; then
local expl ret=1
_comp_mesg=yes
_tags "$2" && while _next_label "$2" expl "$3"; do
compadd ${expl:/-X/-x}
ret=0
done
return ret
fi
_tags messages || return 1
if [[ "$1" = -r ]]; then
raw=yes
shift
format="$1"
else
zstyle -s ":completion:${curcontext}:messages" format format ||
zstyle -s ":completion:${curcontext}:descriptions" format format
fi
if [[ -n "$format$raw" ]]; then
[[ -z "$raw" ]] && zformat -f format "$format" "d:$1" "${(@)argv[2,-1]}"
builtin compadd -x "$format"
_comp_mesg=yes
fi
|