From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 20738 invoked from network); 2 Apr 1999 05:06:08 -0000 Received: from sunsite.auc.dk (130.225.51.30) by ns1.primenet.com.au with SMTP; 2 Apr 1999 05:06:08 -0000 Received: (qmail 9528 invoked by alias); 2 Apr 1999 05:05:40 -0000 Mailing-List: contact zsh-users-help@sunsite.auc.dk; run by ezmlm Precedence: bulk X-No-Archive: yes X-Seq: 2281 Received: (qmail 9521 invoked from network); 2 Apr 1999 05:05:26 -0000 From: "Bart Schaefer" Message-Id: <990401210300.ZM32248@candle.brasslantern.com> Date: Thu, 1 Apr 1999 21:03:00 -0800 In-Reply-To: <19990401132851.A16009@swing.cs.rice.edu> Comments: In reply to Sameer Siruguri "Completion fails to search in $PATH" (Apr 1, 1:28pm) References: <19990401132851.A16009@swing.cs.rice.edu> X-Mailer: Z-Mail (4.0b.820 20aug96) To: Sameer Siruguri , zsh-users@sunsite.auc.dk Subject: Re: Completion fails to search in $PATH MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii On Apr 1, 1:28pm, Sameer Siruguri wrote: } Subject: Completion fails to search in $PATH } } When I create a new executable in some directory that is in my $PATH, } completion fails to add that to the list when I press TAB. This appeared on zsh-workers a while back: > On Jul 17, 9:36pm, Greg Badros wrote: > } Subject: auto-rehashing? > } > } Can zsh auto-rehash when I hit tab a second consecutive time when > } completing in a command position? > > How about this: > > function compctl_rehash { rehash; reply=() } > compctl -C -c + -K compctl_rehash + -c > > That says to try command completion, then if that fails, to rehash, and > then (because compctl_rehash empties $reply) to try command completion a > second time. > > -- > Bart Schaefer Brass Lantern Enterprises > http://www.well.com/user/barts http://www.brasslantern.com