Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
Re: <Tab> completion does not insert a slash
- X-seq: zsh-users 26858
- From: Bart Schaefer <schaefer@xxxxxxxxxxxxxxxx>
- To: Peter Slížik <peter.slizik@xxxxxxxxx>
- Cc: Zsh Users <zsh-users@xxxxxxx>
- Subject: Re: <Tab> completion does not insert a slash
- Date: Wed, 4 Aug 2021 10:26:46 -0700
- Archived-at: <https://zsh.org/users/26858>
- In-reply-to: <CAC-uhUA3dDDKQzdSNp9iBDU=X2tUSZcGpZ9iXRvZXyhBvz+v4g@mail.gmail.com>
- List-id: <zsh-users.zsh.org>
- References: <CAC-uhUAy2HxtSguG8=uAXq57tCdUaKy0puR8boH5HQ3LddMmgQ@mail.gmail.com> <CAH+w=7aBE=yhf2jQYxCJW_QZO+xTjRXDk_X0WusS2fBVaEdi0w@mail.gmail.com> <CAC-uhUA3dDDKQzdSNp9iBDU=X2tUSZcGpZ9iXRvZXyhBvz+v4g@mail.gmail.com>
On Wed, Aug 4, 2021 at 9:50 AM Peter Slížik <peter.slizik@xxxxxxxxx> wrote:
>
> It seems like the completion engine cannot choose between the named directory and a local directory of the same name. In reality, they point to the same dir.
>
> Is there a way to fix this behavior?
Yes. The default is to offer all possible completions at the same
time, but you can change that with the tag-order zstyle.
The default behaves mostly like this:
zstyle :completion::complete:cd:: tag-order "local-directories
named-directories"
(all tags in the same space-separated string are offered at the same time)
What you want is more like this:
zstyle :completion::complete:cd:: tag-order local-directories named-directories
You can reverse the order if you prefer to see the named-directories first:
zstyle :completion::complete:cd:: tag-order named-directories local-directories
Anything in a tag you don't include in the list will be offered if
there are no results for the tags you do list.
Messages sorted by:
Reverse Date,
Date,
Thread,
Author