summary refs log tree commit diff
path: root/Completion/Unix/Command/_cowsay
blob: 19e73811ce17e9b97887fff5c081f008082944c5 (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
#compdef cowsay cowthink

local context state line
typeset -A opt_args

_arguments \
  '-e:eye string:' \
  '-f:cowfile:->cowfile' \
  '-T:tongue string:' \
  '-W:wrap column:' \
  '-b[borg mode]' \
  '-d[dead mode]' \
  '-g[greedy mode]' \
  '-h[help]' \
  '-l[list]' \
  '-n[no wordwrap]' \
  '-p[paranoia mode]' \
  '-s[stoned mode]' \
  '-t[tired mode]' \
  '-w[wired mode]' \
  '-y[youthful mode]' \
  ':message:' && return 0

case "$state" in
  (cowfile)
  compadd ${=${(f)"$($service -l 2>/dev/null)"}:#*\:} || _files
  ;;
esac