about summary refs log tree commit diff
path: root/Completion/Unix/Command/_kvno
blob: 812d728de6dd2ab81c4c6e5ca6e912b5d0941ac0 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
#compdef kvno

_arguments \
	'-c[credentials cache]:cache:_files' \
	'-e[enctype]:enctype:' \
	'-q[suppress printing]' \
	'-h[help]' \
	'-4[kerberos 4 tickets]' \
	':principal:->principal' && return 0

case "$state" in
	(principal)
	if [[ -prefix host/ ]]; then
	  compset -P host/
	  _hosts
	else
	  _alternative \
	    'users:user:_users' \
	    'services:service:compadd -S/ host'
	fi
	;;
esac