From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 8555 invoked from network); 29 May 2000 09:54:56 -0000 Received: from sunsite.auc.dk (130.225.51.30) by ns1.primenet.com.au with SMTP; 29 May 2000 09:54:56 -0000 Received: (qmail 19716 invoked by alias); 29 May 2000 09:54:45 -0000 Mailing-List: contact zsh-workers-help@sunsite.auc.dk; run by ezmlm Precedence: bulk X-No-Archive: yes X-Seq: 11632 Received: (qmail 19709 invoked from network); 29 May 2000 09:54:45 -0000 Date: Mon, 29 May 2000 11:54:33 +0200 (MET DST) Message-Id: <200005290954.LAA04335@beta.informatik.hu-berlin.de> From: Sven Wischnowsky To: zsh-workers@sunsite.auc.dk In-reply-to: "Bart Schaefer"'s message of Sun, 28 May 2000 18:14:51 +0000 Subject: Re: _path_files and glob qualifiers Bart Schaefer wrote: > zagzig[20] zstyle -L | grep completer > zstyle ':completion:*' completer _oldlist _expand _complete _match _ignored _approximate _prefix > > At first I thought the following was a problem with _expand: > > zagzig[21] echo *zshenv(D) > .zshenv zshenv > zagzig[22] ls *zshenv(D) > zagzig[23] ls zshenv > Completing corrections > zshenv > Completing original > *zshenv(D) > > Comparing an example that does work against the above via ^X?, I find that > the real problem is that on line 305, _path_files tests [[ ! -o globdots ]] > and therefore fails to generate dot-files as possible matches, even though > the pattern includes the glob-dots qualifier. > > A potential solution is to change [[ "$PREFIX" = .* ]] on lines 305 and 311 > to [[ "$PREFIX" = (.*|*\([^^]#D*\)) ]] or something like that, but I'm not > entirely sure if that's correct (particularly when there is a suffix). It > might instead be necessary to test earlier and setopt localoptions globdots > if the qualifier is spotted. Hrm. Think of *(^.^D) and of *(^.,D) etc. > But then there's the problem of generalizing to other qualifiers ... Maybe when doing matching, we should copy all qualifiers from the line to the patterns used when generating matches (and remove the qualifiers for matching purposes). Bye Sven -- Sven Wischnowsky wischnow@informatik.hu-berlin.de