From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 606 invoked from network); 1 Jun 2001 07:31:44 -0000 Received: from sunsite.dk (130.225.51.30) by ns1.primenet.com.au with SMTP; 1 Jun 2001 07:31:44 -0000 Received: (qmail 10222 invoked by alias); 1 Jun 2001 07:31:35 -0000 Mailing-List: contact zsh-workers-help@sunsite.dk; run by ezmlm Precedence: bulk X-No-Archive: yes X-Seq: 14629 Received: (qmail 10210 invoked from network); 1 Jun 2001 07:31:34 -0000 From: Sven Wischnowsky Date: Fri, 1 Jun 2001 09:30:36 +0200 (MET DST) Message-Id: <200106010730.JAA12419@beta.informatik.hu-berlin.de> To: zsh-workers@sunsite.dk Subject: Re: Bug#99095: Process completion for gdb In-Reply-To: <20010531135843.A16416@dman.com> Clint Adams wrote: > > I thought about something like that when I wrote _gdb. The problem is > > if there is no file matching *core. Then the first would complete all > > files (or directories), too. And since they may be in different groups, > > they would be shown twice. > > > > Obviously, I didn't find a solution... > > One could rely on the output of file(1), but that's ridiculously expensive. > Why not an option to _path_files that doesn't add any matches if the > pattern is not met? That's what _path_files always does, only _files will re-try with directories and all files. _gdb is rather old and because we've added all that tag-order and file-patterns stuff in the meantime, I would almost suggest to just use the `_files -g "*core"' you suggested. Users can then always use the two styles to change that if they want (we could add a comment to _gdb about that, asking users to tell us why they need it -- if the way their systems handle core dumps is the reason for it). Of course, they can now use the file-patterns style to change it to use that pattern, too. As I said, I had thought about these things when I wrote _gdb, I just wasn't sure if `*core' is a good enough pattern for all systems. And I probably didn't ask back then. So, I would be happy if you choose to change the call to _files, and since noone complained that that would break core file completion on their system... Bye Sven -- Sven Wischnowsky wischnow@informatik.hu-berlin.de