https://github.com/z-shell/ls_colors
📦 ❮ Zi Package - LS_COLORS ❯
https://github.com/z-shell/ls_colors
ls-colors zpackage zsh zshell
Last synced: 6 months ago
JSON representation
📦 ❮ Zi Package - LS_COLORS ❯
- Host: GitHub
- URL: https://github.com/z-shell/ls_colors
- Owner: z-shell
- License: mit
- Created: 2021-11-06T02:34:55.000Z (about 4 years ago)
- Default Branch: main
- Last Pushed: 2023-02-11T10:43:40.000Z (almost 3 years ago)
- Last Synced: 2025-05-05T17:23:34.795Z (9 months ago)
- Topics: ls-colors, zpackage, zsh, zshell
- Homepage: https://wiki.zshell.dev
- Size: 30.3 KB
- Stars: 13
- Watchers: 1
- Forks: 3
- Open Issues: 0
-
Metadata Files:
- Readme: docs/README.md
- License: LICENSE
- Codeowners: .github/CODEOWNERS
Awesome Lists containing this project
README
Package source:
Tarball
Git
Node
Gem
Status:
➖
✔️ (default)
❌
❌
### Available `pack''` invocations
```zsh
# Download the default profile
zi pack for ls_colors
# Download the no-zsh-completion profile
zi pack"no-zsh-completion" for ls_colors
# Download the no-dir-color-swap profile
zi pack"no-dir-color-swap" for ls_colors
```
### Default Profile
Provides the LS_COLORS definitions for GNU `ls`, `ogham/exa` and also setups
zsh-completion system to use the definitions. It also edits the color for the
directory (see the details in the `no-dir-color-swap` profile section).
The ZI command executed will be equivalent to:
```zsh
zi lucid reset \
atclone"[[ -z \${commands[dircolors]} ]] && local P=g
\${P}sed -i '/DIR/c\DIR 38;5;63;1' LS_COLORS
\${P}dircolors -b LS_COLORS >! clrs.zsh" \
atpull'%atclone' pick"clrs.zsh" nocompile'!' \
atload'zstyle ":completion:*:default" list-colors "${(s.:.)LS_COLORS}";' for \
trapd00r/LS_COLORS
```
### `no-zsh-completion` Profile
Provides the LS_COLORS definitions for GNU `ls`, `ogham/exa` but doesn't set up
the zsh-completion system to use them.
The ZI command executed will be equivalent to:
```zsh
zi lucid reset \
atclone"[[ -z \${commands[dircolors]} ]] && local P=g
\${P}sed -i '/DIR/c\DIR 38;5;63;1' LS_COLORS
\${P}dircolors -b LS_COLORS >! clrs.zsh" \
atpull'%atclone' pick"clrs.zsh" nocompile'!' for \
trapd00r/LS_COLORS
```
### `no-dir-color-swap` Profile
Provides the LS_COLORS definitions like the `default` profile, however doesn't
edit the definitions file and doesn't change the color for directories. The
color is being edited in the default profile because the author found it to be
too dark.
The ZI command executed will be equivalent to:
```zsh
zi lucid \
atclone"[[ -z \${commands[dircolors]} ]] && local P=g
\${P}dircolors -b LS_COLORS >! clrs.zsh" \
atpull'%atclone' pick"clrs.zsh" nocompile'!' \
atload'zstyle ":completion:*:default" list-colors "${(s.:.)LS_COLORS}";' for \
trapd00r/LS_COLORS
```
---
> This repository compatible with [ZI](https://github.com/z-shell/zi)
The [trapd00r/LS_COLORS](https://github.com/trapd00r/LS_COLORS) zsh package that uses the [zsh-string-lib](https://github.com/z-shell/zsh-string-lib) to automatically:
- get the plugin's Git repository OR release-package URL,
- get the list of the recommended ices for the plugin,
- there can be multiple lists of ices,
- the ice lists are stored in _profiles_; there's at least one profile, _default_,
- the ices can be selectively overridden.