From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 2643 invoked from network); 17 Sep 2001 08:19:35 -0000 Received: from sunsite.dk (130.225.51.30) by ns1.primenet.com.au with SMTP; 17 Sep 2001 08:19:35 -0000 Received: (qmail 9756 invoked by alias); 17 Sep 2001 08:19:24 -0000 Mailing-List: contact zsh-workers-help@sunsite.dk; run by ezmlm Precedence: bulk X-No-Archive: yes X-Seq: 15822 Received: (qmail 9742 invoked from network); 17 Sep 2001 08:19:22 -0000 X-Authentication-Warning: zone2.gcu-squad.org: Host Mix-Amiens-106-1-123.abo.wanadoo.fr [193.250.130.123] claimed to be asyd.debian-fr.org Date: Mon, 17 Sep 2001 00:05:05 +0200 From: Bruno Bonfils To: zsh-workers Subject: GPG completion function Message-ID: <20010917000505.A5637@debian-fr.org> Mail-Followup-To: Bruno Bonfils , zsh-workers Mime-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="DKU6Jbt7q3WqK7+M" Content-Disposition: inline User-Agent: Mutt/1.2.5i --DKU6Jbt7q3WqK7+M Content-Type: multipart/mixed; boundary="Nq2Wo0NMKNjxTN9z" Content-Disposition: inline --Nq2Wo0NMKNjxTN9z Content-Type: text/plain; charset=iso-8859-1 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable hi all, i submit you my first completion function (for gpg) i don't have finish completely, but i send you in order to have comments/idea. _any_ comments/ideas are welcome thank you very much for this very powerfull shell (i fall in love :) ++ --=20 Bruno Bonfils Admin Sys Linux http://www.darksnow.org http://www.debian-fr.org Selon les logs, il y a des pertes de porteuses, mais surtout des requ=EAtes de d=E9connexion qui viennent de votre machine. Il faut se rappeler que windows 95 est un systeme bio-d=E9gradable. -+- Support technique HOL in: Guide du Cabaliste Usenet - CQFD ! -+- --Nq2Wo0NMKNjxTN9z Content-Type: text/plain; charset=us-ascii Content-Disposition: attachment; filename=_gpg Content-Transfer-Encoding: quoted-printable #compdef gpg # Author : Bruno Bonfils # Date : Sept 2001 local context state line typeset -A opt_args _pub-keys-list () { local keys_list # i must rewrite this line using pattern matching for name in `gpg --list-keys | awk '/^pub/ { print $NF }' | tr "<|>" -d` do=09 compadd "$name"; done } _arguments -C -s \ '-a[create ASCII armored output]' \ '-o[write output to file]:_files attachment:_files' \ '-u[use name as the user ID to sign]'\ '-b[make a detached signature]' \ '-s[sign a file]:file attachment:_files' \ '-e[encrypt data. this option may be combined with --sign]' \ '-h[help]' \ '--clearsign[make a clear text signature]' \ '--check-sigs[verify all signatures]' \ '--decrypt[decrypt file or stdin]:file attachment:_files' \ '--delete-key[remove key from public keyring]:key attachment:_pub-keys-lis= t' \ '--delete-secret-key[remove key from public & private keyring]' \ '--delete-secret-and-public-key[remove key from private & public keyring]'= \ '--edit-key[a menu for edit yours keys]:key attachment:_pub-keys-list' \ '--export[export all key from all keyrings]' \ '--export-all[export all key and not OpenPGP compatible keys]' \ '--export-ownertrust[list the assigned ownertrust values in ASCII format]'= \ '--export-secret-keys[export a list of secret keys]' \ '--export-secret-subkeys[same as --export but export the secret keys inste= ad'] \ '--fast-import[import a file without build trustdb]:_files attachment:_fil= es' \ '--fingerprint[list all keys with their fingerprints]' \ '--gen-key[generate a new pair key]' \ '--gen-random[emit random bytes of the given level quality]' \ '--gen-prime[use the source, luke :-)]' \ '--import[import a gpg key from a file]:_files attachment:_files' \ '--import-ownertrust[update the trustdb with a file]:_files attachment:_fi= les'\ '--keyserver[use server for send/recv keys]:_hosts attachment:_hosts' \ '--list-keys[list all keys]:key attachment:_pub-keys-list' \ '--list-public-keys[list all public keys]:key attachment:_pub-keys-list' \ '--list-secret-keys[list all secret keys]:key attachment:_pub-keys-list' \ '--list-packets[list only the sequence of packets]' \ '--lsign-key[sign a key but mark not is as non-exportable]:key attachment:= _pub-keys-list' \ '--print-md[Print message digest of the given algorithm for all given file= s]' \ '--recv-keys[receive a list of keys from a keyserver]' \ '--send-keys[send keys to a keyserver]:key attachment:_pub-keys-list' \ '--sign-key[sign a key]:key attachment:_pub-keys-list '\ '--store[store only]' \ '--trusted-key[assume that the specified key is trustworthy]' \ '--verify[verify a signature]' \ '--verify-files[verify a list of files]:file attachment:_files' \ && return 0 return 1 --Nq2Wo0NMKNjxTN9z-- --DKU6Jbt7q3WqK7+M Content-Type: application/pgp-signature Content-Disposition: inline -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.0.6 (GNU/Linux) Comment: Pour information voir http://www.gnupg.org iEYEARECAAYFAjulIhEACgkQ8dj4f/OdzPUlMACcDkYVvPxq/aTvcFpB5gPZY9dg haUAn2RX9SCvoUO+G4rQ7B/68KNbXTrK =+T8t -----END PGP SIGNATURE----- --DKU6Jbt7q3WqK7+M--