about summary refs log tree commit diff
path: root/Completion/Base/_condition
blob: c617d9d90ef8e29e679386eee6415248f45f5134 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
#compdef -condition-

local prev="$words[CURRENT-1]"

if [[ "$prev" = -o ]]; then
  _options
elif [[ "$prev" = -([no]t|ef) ]]; then
  _files
else
  local ret=1

  _files && ret=0
  compgen -v && ret=0

  return ret
fi