zoxide icon indicating copy to clipboard operation
zoxide copied to clipboard

Directory Color Issues in Interactive Mode

Open NoobGajen opened this issue 1 year ago • 7 comments

I am facing some color issues in interactive mode in the zoxide tool, possibly due to an incorrect implementation of LS_COLORS. I'm using zsh 5.9 (x86_64-pc-linux-gnu) on Arch Linux, and I tested the zoxide tool on some Debian-based distros as well and the issue was same.

I am a big fan of the zoxide tool and have a huge respect for your work. Could you please help resolve this color issue? AND Is there any way to manually set LS_COLORS by adding an extra flag or changing some lines in the configuration files?

Thank you!

image

NoobGajen avatar May 25 '24 05:05 NoobGajen

  1. What are the colours supposed to look like?
  2. What's the value of LS_COLORS?

ajeetdsouza avatar May 25 '24 09:05 ajeetdsouza

I am not using any sort of LS_COLORS with my shell.
Do I need to use it?

BTW, I am using pure Zsh in my Arch Linux. I remember I was getting the same issue when I was customizing my Zsh shell because of LS_COLORS customization. I was not able to fix that issue, so I left out the LS_COLORS customization.

The customization was something like this: when I added this line to my .zshrc file, I started getting the same color issue with my directories as I am getting in the zoxide tool:

zstyle ':completion:*' list-colors ${(s.:.)LS_COLORS} 'di=1;34'

NoobGajen avatar May 25 '24 09:05 NoobGajen

Are you using the package lsd as a replacement for plain ls, by any chance? I found this bug report because I was having the exact same issue as you, with pretty much the same unreadable colour combination as you.

If you have made an alias so that the command 'ls' actually executes lsd, try /bin/ls -lh --color and check if the colours are different (and maybe even more readable) as they were for me. If so, than you are experiencing the exact same issue as I did. So I suspect it's not a bug after all.

I solved it by configuring the LS_COLORS variable (see the Arch Wiki; personally I'm using the package vivid now). Now zoxide (and fzf) much more legible.

JayBeeFOSS avatar Jul 17 '24 05:07 JayBeeFOSS

I fixed it by adding line to the config.fish: set LS_COLORS "$LS_COLORS:ow=34;01" OW states for STICKY_OTHER_WRITABLE In my case all folders from Windows have this sticky bit. Of course, I'm wowking in WSL

ozinka avatar Aug 11 '24 09:08 ozinka

Having the same issue. Did you manage to solve it ? I'm using zsh

tommdq avatar Mar 10 '25 17:03 tommdq

Having the same issue. Did you manage to solve it ? I'm using zsh

Doesn't my solution work for you?

ozinka avatar Mar 10 '25 19:03 ozinka

Having the same issue. Did you manage to solve it ? I'm using zsh

Doesn't my solution work for you?

Dude! Sorry, I read fish and posted anyway. Solved by changing the LS_COLORS in my zsh config. Thanks!!

Added this line in my .zshrc file export LS_COLORS="${LS_COLORS}:ow=34;01"

tommdq avatar Mar 11 '25 18:03 tommdq