sainnhe / edge

Clean & Elegant Color Scheme inspired by Atom One and Material
MIT License
860 stars 56 forks source link

zsh: thoughts about adding LS_COLORS and using them for completion #40

Closed xse closed 2 years ago

xse commented 2 years ago

Hey, First of, thanks a lot for that edge color scheme i love it! Checking out that zsh part, I'm wondering if you ever thought about creating a custom LS_COLORS themed in the same way ? I tried a bit (vivid is easier than dircolors), not totally here yet but zsh completion can use LS_COLORS with italics and so on. Here's an example: 2021-11-12 16_44_16-OpenSSH SSH client

with ~/.zshrc containing an export LS_COLORS='.... and also:

# use LS_COLORS for completion, TODO: 'ma' is the selected item like:
# zstyle ':completion:*:default' list-colors ${(s.:.)LS_COLORS} "ma=48;5;153;1"
zstyle ':completion:*:default' list-colors ${(s.:.)LS_COLORS}

Have a good day!

sainnhe commented 2 years ago

Thanks for your suggestion :)

IMO, the zsh theme is only for shell prompt, and should not contain any extra configurations. We should follow the Unix philosophy: "Write programs that do one thing and do it well."

If we need LS_COLORS to be set, that should be placed in zshrc. My configuration will use terminal color scheme to display ls colors: https://github.com/sainnhe/dotfiles/blob/e68c7606484a67f7da79196021dfe50b0b973704/.zshrc#L98-L99