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

Re: PATCH: _history_complete_word



Bringing more dead topics back to life ...

Adam Spiers (adam@xxxxxxxxxx) wrote:
> Just noticed another new quirk with h-c-w now.  I have:
> 
>   zstyle ':completion:*:descriptions' format '%B---- %d%b'
>   zstyle ':completion:*:history-words' stop verbose
>   zstyle ':completion:*:history-words' remove_all_dups yep
>                                                         
> The first time I press M-/ the message `---- history word' appears,
> which means that I have to press it twice to get the first match,
> which shouldn't really happen unless the `list' style is turned on.
> How can this be fixed?

This tiny nit has grown into an itch big enough I need to scratch it.
These days I also have 

    zstyle ':completion:*:history-words' list false

set, so I don't even get the message appearing.  This gives the
impression of the first keystroke just being swallowed.  This is
presumably because the

  [[ $LASTWIDGET = _history-complete-* &&
     ( -n "$compstate[old_list]" || -n $_hist_stop ) ]]

condition returns false, so on the first stroke, the matches are
generated but nothing else happens.  I'm not sure what the best
solution is.



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