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

Re: Funky list-colors



On Thu, 5 Dec 2019 at 00:28, Bart Schaefer <schaefer@xxxxxxxxxxxxxxxx> wrote:
> OK, so what you want here is not to fiddle with the way completion
> applies colors to the grid, but the way it populates the grid with
> file names.
>
> The first and most straightforward thing you might do is set the
> LIST_TYPES option (it should be set by default, but maybe it's become
> turned off).  This puts an identifiying character at the end of the
> file name, e.g., character devices get a "%", block devices get  a
> "#", directories a "/", symlinks an "@", etc.  (Oddly I can't find a
> complete description of the identifying characters in the manual.)  If
> you have this set and are not seeing these marks, it may be because
> your completion function is not using "compadd -f" to tell the
> internals to treat the names as files.

This seems a less powerful than the hacky printable-LS_COLORS idea,
which I overall like. From experience, such things often result in
unpredictable and highly surprising + valuable solutions. Maybe it's
worth opening this door? In a most optimistic scenario, the code would
have to do a few isprints…

-- 
Sebastian Gniazdowski
News: https://twitter.com/ZdharmaI
IRC: https://kiwiirc.com/client/chat.freenode.net:+6697/#zplugin
Blog: http://zdharma.org



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