From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 9969 invoked from network); 11 Mar 2003 05:38:55 -0000 Received: from sunsite.dk (130.225.247.90) by ns1.primenet.com.au with SMTP; 11 Mar 2003 05:38:55 -0000 Received: (qmail 8056 invoked by alias); 11 Mar 2003 05:38:47 -0000 Mailing-List: contact zsh-workers-help@sunsite.dk; run by ezmlm Precedence: bulk X-No-Archive: yes X-Seq: 18334 Received: (qmail 8049 invoked from network); 11 Mar 2003 05:38:47 -0000 Received: from localhost (HELO sunsite.dk) (127.0.0.1) by localhost with SMTP; 11 Mar 2003 05:38:47 -0000 X-MessageWall-Score: 0 (sunsite.dk) Received: from [219.163.13.59] by sunsite.dk (MessageWall 1.0.8) with SMTP; 11 Mar 2003 5:38:46 -0000 Received: (qmail 14221 invoked from network); 11 Mar 2003 14:38:45 +0900 Received: from unknown (HELO tempest.nemui.org.nemui.org) (192.168.51.1) by 192.168.51.1 with SMTP; 11 Mar 2003 14:38:45 +0900 Date: Tue, 11 Mar 2003 14:38:33 +0900 Message-ID: <87r89eiht2.wl@nemui.org> From: Tatsuki Sugiura To: zsh-workers@sunsite.dk Subject: PATCH _hosts: can complete hosts listed on ~/.ssh/config User-Agent: Wanderlust/2.9.15 (Unchained Melody) SEMI/1.14.4 (Hosorogi) FLIM/1.14.4 (=?ISO-8859-4?Q?Kashiharajing=FE-mae?=) APEL/10.4 Emacs/21.2 (i386-pc-linux-gnu) MULE/5.0 (=?ISO-2022-JP?B?GyRCOC1MWhsoQg==?=) X-Face: %#SbsX5Ajq`)JKPGXyq8Cn6"<`&M~n\?,}`vYU7[}gM!q_K=\v6[}y8&R:Dy3O0Ymmw$@>T $Ys$^Tw8ghB'uxX)I(n_x\5RQ|s'D0m$,"I^\S X-GPG-Fingerprint: C4BC EDCC 50B2 2D7B 4A85 4A13 6CAD 85CE 4502 FDC2 X-Public-Key: http://pgp.nic.ad.jp:11371/pks/lookup?op=get&search=0x4502FDC2 X-GPG-KeyID: 4502FDC2 X-Moe: Vampire/lilith MIME-Version: 1.0 (generated by SEMI 1.14.4 - "Hosorogi") Content-Type: text/plain; charset=US-ASCII Hello. Usually, "/etc/hosts" dos not contain hostname to wish to complete. This pactch parse ~/.ssh/config and pick up hosts listed as "Host" or "HostName". What about this? ============== --- _hosts.orig 2003-03-11 14:21:35.000000000 +0900 +++ _hosts 2003-03-11 14:22:54.000000000 +0900 @@ -1,12 +1,15 @@ -#compdef ftp ping rwho rup xping traceroute host aaaa zone mx ns soa txt +#compdef ftp ping rwho rup xping traceroute host aaaa zone mx ns soa txt mtr dnsip hping2 hping nmap tcptraceroute local expl hosts if ! zstyle -a ":completion:${curcontext}:hosts" hosts hosts; then (( $+_cache_hosts )) || : ${(A)_cache_hosts:=${(s: :)${(ps:\t:)${${(f)~~"$(