From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 17180 invoked by alias); 30 Dec 2013 20:20:34 -0000 Mailing-List: contact zsh-workers-help@zsh.org; run by ezmlm Precedence: bulk X-No-Archive: yes List-Id: Zsh Workers List List-Post: List-Help: X-Seq: 32205 Received: (qmail 23882 invoked from network); 30 Dec 2013 20:20:28 -0000 X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on f.primenet.com.au X-Spam-Level: X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00,RCVD_IN_DNSWL_NONE autolearn=ham version=3.3.2 From: Bart Schaefer Message-id: <131230122026.ZM23634@torch.brasslantern.com> Date: Mon, 30 Dec 2013 12:20:26 -0800 In-reply-to: <131230111716.ZM23440@torch.brasslantern.com> Comments: In reply to Bart Schaefer "Re: zsh-5.0.4: cd autocompletion broken for "../" when CDPATH is set" (Dec 30, 11:17am) References: <52C1884C.4050101@aon.at> <131230111716.ZM23440@torch.brasslantern.com> X-Mailer: OpenZMail Classic (0.9.2 24April2005) To: zsh-workers@zsh.org Subject: Re: zsh-5.0.4: cd autocompletion broken for "../" when CDPATH is set MIME-version: 1.0 Content-type: text/plain; charset=us-ascii On Dec 30, 11:17am, Bart Schaefer wrote: } Subject: Re: zsh-5.0.4: cd autocompletion broken for "../" when CDPATH is } } On Dec 30, 3:50pm, Martin Birgmeier wrote: } } } } Since the upgrade to 5.0.4, whenever I type (in any directory) } } } } # cd ../ } } } } then instead of autocompleting the entries in .., I get all entries in } } all of the CDPATH components. } } - if [[ $PREFIX != (\~|/|./|../)* ]]; then } + if [[ $PREFIX != (\~|/|./|../)* && -z $tmpWpath ]]; then ... in which case the reference to tmpWpath in that block would not be needed at all. Hmm. That's not right. What we want is more like: diff --git a/Completion/Zsh/Command/_cd b/Completion/Zsh/Command/_cd index b9860ff..6b8d7eb 100644 --- a/Completion/Zsh/Command/_cd +++ b/Completion/Zsh/Command/_cd @@ -63,7 +63,7 @@ else fi fi - if [[ $PREFIX != (\~|/|./|../)* ]]; then + if [[ $PREFIX != (\~|/|./|../)* && $IPREFIX != ../* ]]; then local tmpcdpath alt alt=() So please ignore 32203.