Zsh Mailing List Archive
Messages sorted by: Reverse Date, Date, Thread, Author

Re: Dynamic named directories and completion



On Mon, Feb 26, 2018 at 3:47 PM, Peter Stephenson
<p.stephenson@xxxxxxxxxxx> wrote:
> On Mon, 26 Feb 2018 08:53:00 -0500
> Scott Frazer <frazer.scott@xxxxxxxxx> wrote:
>> Yes, M-x complete-word does indeed work!  I still need to try some of the
>> patches from later in this thread ...
>
> Glad it's not totally shrouded in obscurity...
>
> Would generally recommend the combination of complete-word as binding
> for tab + use of the expand completer (which I fixed somewhere else in
> this thread but am still to commit) as this is much more configurable.
>
> To turn it on you'd do something like
>
> zstyle ':completion:*' completer _expand _complete _ignored
> bindkey '^i' complete-word
>
> but there are many more exotic possibilities.
>
> I'll have a look at expand-or-complete word, too.
>
> (Ideally, in fact, whether or not we expand ~[whatever] needs
> configuring --- because this is dynamic completion you might decide to
> expand it to freeze the path for future use.  I'll look at that if I get
> the chance.  This is the sort of reason for using the expand completer
> I'm talking about.)

In this type of situation I usually explicitly press expand-word (^X*
by default I believe).

-- 
Mikael Magnusson



Messages sorted by: Reverse Date, Date, Thread, Author