From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 10859 invoked by alias); 18 Jun 2015 11:38: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: 35516 Received: (qmail 29955 invoked from network); 18 Jun 2015 11:38:32 -0000 X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on f.primenet.com.au X-Spam-Level: X-Spam-Status: No, score=-2.7 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,FREEMAIL_FROM,RCVD_IN_DNSWL_LOW,RCVD_IN_MSPIKE_H2 autolearn=ham autolearn_force=no version=3.4.0 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :content-type; bh=GVzjKmIq7Esl0CmTyUjFETbctK57mTy5cQnCjXUDGLo=; b=DIKhRrwVs0y07kh7Knv/Mfo/PEauNZx1MmdJOF6Ptu6TBnStKONL21RkcTSSpjhDOk oFdJ7g5SF3yMaHQNH4797dqntraugBH2T4oLglrkj7gORdZRXJrNy90gdI0dFRl0reqb B5djzmXIXafRyVR5JwV5SCLIEDK4bKkdcr65FK9nxnAFFB7ablbV4EFVT0bSSw72tfIj hThJlsFVdhY4SOUwwRurOCy3K1OCJmEMnYIQkQj1wZ6+ZAabqfOy2zw5wqx+zKc7XOwp 18uGnswBgw3PLU6k1Qr0iWxoMght2lfrfKfH5pxydZRB3AJ/c0egVdxV8gVDAZmtKmBn RO3Q== MIME-Version: 1.0 X-Received: by 10.43.40.130 with SMTP id tq2mr5335610icb.46.1434627510321; Thu, 18 Jun 2015 04:38:30 -0700 (PDT) In-Reply-To: <1434626896-18641-1-git-send-email-mikachu@gmail.com> References: <1434626896-18641-1-git-send-email-mikachu@gmail.com> Date: Thu, 18 Jun 2015 13:38:30 +0200 Message-ID: Subject: Re: PATCH: One small step towards making ~[foo] work From: Mikael Magnusson To: zsh workers Content-Type: text/plain; charset=UTF-8 On Thu, Jun 18, 2015 at 1:28 PM, Mikael Magnusson wrote: > I'm not sure if the first hunk does anything useful, because I'm unable > to make much else after that work yet. The second hunk at least makes it > so ~[foo/]/ tries ~[foo/] as the prefix instead of ~[foo. This results > in ~[m48/] completing to files inside the directory I want but, > it lists it as "corrections (errors: 1)". Doing ~[m48/]/ produces a > "no match" error. > > ~[m48] still produces nonsense results like ~man ~messagebus etc, > I guess it thinks [m48] is a character class. I don't know where to hook > into that properly to redirect it to _path_files(?). > > (The %%]*] is not strictly correct, zsh currently accepts > ~[foo]blabla/hello as an expansion to bazblabla/hello if ~[foo] expands > to baz, which is possibly not something we should allow. It feels weird > anyway). I realized my ~[foo] expansions where foo doesn't contain a / seem to work pretty well, as long as you put the trailing slash after manually (or completion puts it there for you), so there must be somewhere else that doesn't know about the ~[foo] syntax in the completion code. Any idea where that might be? I can live with ~[foo] not working for now :). I can just invoke expand-word after all. -- Mikael Magnusson