Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
Re: [PATCH] Don't complete dirs as suffix aliases
- X-seq: zsh-workers 50205
- From: Peter Stephenson <p.w.stephenson@xxxxxxxxxxxx>
- To: Zsh hackers list <zsh-workers@xxxxxxx>
- Subject: Re: [PATCH] Don't complete dirs as suffix aliases
- Date: Wed, 11 May 2022 12:18:47 +0100 (BST)
- Archived-at: <https://zsh.org/workers/50205>
- Importance: Medium
- In-reply-to: <CAHLkEDt2tmYezgO=nZBkpW91QSFD0Bec6BftwpWynoFOSRm9nA@mail.gmail.com>
- List-id: <zsh-workers.zsh.org>
- References: <CAHLkEDtdcUO+Oox91c2VOgUTZHpzufcQeGWvR7JmBm=p3Z59CA@mail.gmail.com> <CAHYJk3QvqLCetsEv7pS4AocXGu-VV4+D9jwacMeJmBqQ1Ug_SA@mail.gmail.com> <CAHLkEDt2tmYezgO=nZBkpW91QSFD0Bec6BftwpWynoFOSRm9nA@mail.gmail.com>
> On 11 May 2022 at 11:44 Marlon Richert <marlon.richert@xxxxxxxxx> wrote:
> On Wed, May 11, 2022 at 11:03 AM Mikael Magnusson <mikachu@xxxxxxxxx> wrote:
> >
> > On 5/11/22, Marlon Richert <marlon.richert@xxxxxxxxx> wrote:
> > > ...because suffix aliases don't work with directories.
> >
> > In what sense do they not work?
>
> % zsh -f
> % alias -s marlon=echo
> % mkdir hello.marlon
> % hello.marlon
> zsh: command not found: hello.marlon
So I think you need to change the line you added to
[[ -o autocd ]] || pat+='(#q^/)'
Not a particularly obvious use case, but presumably best not to break it.
pws
Messages sorted by:
Reverse Date,
Date,
Thread,
Author