From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 18134 invoked from network); 5 Nov 1999 09:25:00 -0000 Received: from sunsite.auc.dk (130.225.51.30) by ns1.primenet.com.au with SMTP; 5 Nov 1999 09:25:00 -0000 Received: (qmail 29508 invoked by alias); 5 Nov 1999 09:24:55 -0000 Mailing-List: contact zsh-workers-help@sunsite.auc.dk; run by ezmlm Precedence: bulk X-No-Archive: yes X-Seq: 8562 Received: (qmail 29501 invoked from network); 5 Nov 1999 09:24:55 -0000 Date: Fri, 5 Nov 1999 10:24:41 +0100 (MET) Message-Id: <199911050924.KAA02680@beta.informatik.hu-berlin.de> From: Sven Wischnowsky To: zsh-workers@sunsite.auc.dk In-reply-to: "Bart Schaefer"'s message of Fri, 5 Nov 1999 09:00:47 +0000 Subject: Re: setopt globdots in _path_files Bart Schaefer wrote: > On Nov 4, 8:19pm, Oliver Kiddle wrote: > } Subject: setopt globdots in _path_files > } > } _path_files in bart-8 does a setopt globdots. > > This was the second hunk in Sven's patch of 8479. It would probably be > better to back out that hunk, rather than simply remove globdots. I suggest just using this patch instead of Oliver's. The problem with just removing the `globdots' is that then even `.../.' doesn't work any more (if globdots is unset by the user). Bye Sven diff -u oldcompletion/Core/_path_files Completion/Core/_path_files --- oldcompletion/Core/_path_files Thu Nov 4 14:50:48 1999 +++ Completion/Core/_path_files Fri Nov 5 10:20:58 1999 @@ -10,7 +10,7 @@ typeset -U prepaths exppaths -setopt localoptions nullglob rcexpandparam globdots +setopt localoptions nullglob rcexpandparam unsetopt markdirs globsubst shwordsplit nounset local sopt='-' gopt='' opt @@ -210,10 +210,15 @@ # Get the matching files by globbing. if [[ "$tpre$tsuf" = */* ]]; then - tmp1=( ${^tmp1}*(-/) ) + tmp2=( ${^tmp1}*(-/) ) + [[ ! -o globdots && "$PREFIX" = .* ]] && + tmp2=( "$tmp1[@]" ${^tmp1}.*(-/) ) else - tmp1=( ${^tmp1}${^~pats} ) + tmp2=( ${^tmp1}${^~pats} ) + [[ ! -o globdots && "$PREFIX" = .* ]] && + tmp2=( "$tmp1[@]" ${^tmp1}.${^~pats} ) fi + tmp1=( "$tmp2[@]" ) if [[ -n "$PREFIX$SUFFIX" ]]; then # See which of them match what's on the line. -- Sven Wischnowsky wischnow@informatik.hu-berlin.de