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

Re: Add completion suffix highlighting



2009/12/5 Peter Stephenson <p.w.stephenson@xxxxxxxxxxxx>:
> On Fri, 4 Dec 2009 22:53:58 +0100
> Mikael Magnusson <mikachu@xxxxxxxxx> wrote:
>> I have a friend who just started using zsh a while ago, and she
>> complained about / being removed when she pressed enter after
>> completing a directory to rsync. Apparently rsync behaves differently
>> with and without the / in place. We tried setting
>> ZLE_REMOVE_SUFFIX_CHARS to nothing and using zle auto-suffix-retain in
>> an accept-line hook, but then we realized it would be better if you
>> could tell more easily if the suffix would be removed or not. So I
>> whipped this up and somehow it worked on the first try (no guarantees
>> though :). Given my poor track record of posting patches via email,
>> here is a link to the patch, and I'll just paste in the essence of the
>> patch for reference.
>
> I'll commit this as it is with the following documentation and see
> what happens---I think highlighting removable suffixes is actually quite
> intuitive.  Note, however, there are a lot of cases in which bold fonts
> aren't supported.
>
> Thanks.

Ah, I think I meant to add at least the example too, but obviously
forgot, thanks. I also meant to ask if the variable I check for the
suffix length was the correct one, I was somewhat confused when I
discovered the suffix list. Is there any completion that actually uses
the multiple suffix feature?

-- 
Mikael Magnusson



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