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

Re: Completion and dircolors problem



2008/11/30 Thorsten Kampe <thorsten@xxxxxxxxxxxxxxxx>:

> 4.3.6. So this is expected?! As I said I don't set the list-colors
> manually but I let zsh read my LS_COLORS (tip from the user guide
> ("list-colors ${(s.:.)LS_COLORS}")).
>
> So if I understand it correctly the external command dircolors
> understands "LINK target" - while zsh does not ("ln=target") until
> 4.3.9?!

You can filter out the ln with an expression like
${${(s.:.)LS_COLORS}%ln=*}, then you probably want to add an explicit
'ln=0;36' too after. Ie,
zstyle ':completion:*' list-colors ${(s.:.)${LS_COLORS}%ln=*} 'ln=00;36'

Heh, I think I found a bug in ls, ls -l *(@) shows only broken links,
while ls -ld *(@) shows the correct colors, when I've set ln=target.

If you want to be fancy, you can make the above depend on $ZSH_VERSION
too, but it's probably easier to just remove it when you update zsh.

-- 
Mikael Magnusson



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