Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
PATCH: _kvno
- X-seq: zsh-workers 21382
- From: Clint Adams <clint@xxxxxxx>
- To: zsh-workers@xxxxxxxxxx
- Subject: PATCH: _kvno
- Date: Fri, 24 Jun 2005 14:46:20 -0400
- Mail-followup-to: zsh-workers@xxxxxxxxxx
- Mailing-list: contact zsh-workers-help@xxxxxxxxxx; run by ezmlm
This is for MIT krb5, and is ignorant of Kerberos realms, other service
types, and pretty much everything else, but all I care about is the host
completion.
Index: Completion/Unix/Command/_kvno
===================================================================
RCS file: Completion/Unix/Command/_kvno
diff -N Completion/Unix/Command/_kvno
--- /dev/null 1 Jan 1970 00:00:00 -0000
+++ Completion/Unix/Command/_kvno 24 Jun 2005 18:44:36 -0000
@@ -0,0 +1,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
Messages sorted by:
Reverse Date,
Date,
Thread,
Author