From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 24196 invoked from network); 25 May 2008 14:53:07 -0000 X-Spam-Checker-Version: SpamAssassin 3.2.4 (2008-01-01) on f.primenet.com.au X-Spam-Level: X-Spam-Status: No, score=-2.6 required=5.0 tests=AWL,BAYES_00 autolearn=ham version=3.2.4 Received: from news.dotsrc.org (HELO a.mx.sunsite.dk) (130.225.247.88) by ns1.primenet.com.au with SMTP; 25 May 2008 14:53:07 -0000 Received-SPF: none (ns1.primenet.com.au: domain at sunsite.dk does not designate permitted sender hosts) Received: (qmail 42730 invoked from network); 25 May 2008 14:53:00 -0000 Received: from sunsite.dk (130.225.247.90) by a.mx.sunsite.dk with SMTP; 25 May 2008 14:53:00 -0000 Received: (qmail 122 invoked by alias); 25 May 2008 14:52:57 -0000 Mailing-List: contact zsh-workers-help@sunsite.dk; run by ezmlm Precedence: bulk X-No-Archive: yes X-Seq: 25104 Received: (qmail 96 invoked from network); 25 May 2008 14:52:56 -0000 Received: from bifrost.dotsrc.org (130.225.254.106) by sunsite.dk with SMTP; 25 May 2008 14:52:56 -0000 Received: from mtaout01-winn.ispmail.ntl.com (mtaout01-winn.ispmail.ntl.com [81.103.221.47]) by bifrost.dotsrc.org (Postfix) with ESMTP id E595680589A4 for ; Sun, 25 May 2008 16:52:51 +0200 (CEST) Received: from aamtaout02-winn.ispmail.ntl.com ([81.103.221.35]) by mtaout01-winn.ispmail.ntl.com with ESMTP id <20080525145631.SPYL14647.mtaout01-winn.ispmail.ntl.com@aamtaout02-winn.ispmail.ntl.com>; Sun, 25 May 2008 15:56:31 +0100 Received: from pws-pc ([81.107.40.67]) by aamtaout02-winn.ispmail.ntl.com with ESMTP id <20080525145529.SGXL17393.aamtaout02-winn.ispmail.ntl.com@pws-pc>; Sun, 25 May 2008 15:55:29 +0100 Date: Sun, 25 May 2008 15:52:31 +0100 From: Peter Stephenson To: zsh-workers@sunsite.dk Cc: Sykora , 482662@bugs.debian.org Subject: Re: Bug#482662: zsh: completion with locate gives extra output Message-ID: <20080525155231.691a4979@pws-pc> In-Reply-To: <20080524202135.GA18082@scru.org> References: <20080524095358.26811.79795.reportbug@nexus> <20080524135404.GA9888@scru.org> <20080524164656.GA2682@nexus> <20080524202135.GA18082@scru.org> X-Mailer: Claws Mail 3.3.1 (GTK+ 2.12.9; x86_64-redhat-linux-gnu) Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit X-Virus-Scanned: ClamAV 0.91.2/7233/Sun May 25 16:09:09 2008 on bifrost X-Virus-Status: Clean On Sat, 24 May 2008 20:21:35 +0000 Clint Adams wrote: > On Sat, May 24, 2008 at 10:16:56PM +0530, Sykora wrote: > > I just typed "locate" at the prompt and pressed space, followed by tab. > > > > > > $> locate Usage: locate [-d path | --database=path] [-e | -E | --[non-]existing] > > [-i | --ignore-case] [-w | --wholename] [-b | --basename] > > [--limit=N | -l N] [-S | --statistics] [-0 | --null] [-c | --count] > > [-P | -H | --nofollow] [-L | --follow] [-m | --mmap ] [ -s | --stdio ] > > [-A | --all] [-p | --print] [-r | --regex ] [--regextype=TYPE] > > [--max-database-age D] [--version] [--help] > > pattern... > > > > Report bugs to . > > > > Ah, okay. You are using GNU locate and I am using mlocate. > > So _locate is trying to match *(#i)gnu locate*, which does not appear in the > `locate -V` output (nor does it appear in the `locate --version` output). > Does anyone have an older version of findutils handy? Would matching for > *findutils* or (#i)*findutils*gnu* cover all possibilities? Presumably also copying stderr to stdout. Index: Completion/Unix/Command/_locate =================================================================== RCS file: /cvsroot/zsh/zsh/Completion/Unix/Command/_locate,v retrieving revision 1.2 diff -u -r1.2 _locate --- Completion/Unix/Command/_locate 11 Feb 2008 16:28:30 -0000 1.2 +++ Completion/Unix/Command/_locate 25 May 2008 14:50:52 -0000 @@ -11,7 +11,7 @@ ;; (locate) - input="$(_call_program locate $words[1] -V)" + input="$(_call_program locate $words[1] -V 2>&1)" case $input in (*mlocate*) ltype=mlocate @@ -21,7 +21,7 @@ ltype=slocate ;; - (*(#i)gnu locate*) + (*(#i)gnu locate*|*findutils*gnu*) ltype=gnu ;; -- Peter Stephenson Web page now at http://homepage.ntlworld.com/p.w.stephenson/