diff --git a/plugins/eza/README.md b/plugins/eza/README.md index 90e549994..bec1f85cb 100644 --- a/plugins/eza/README.md +++ b/plugins/eza/README.md @@ -65,6 +65,29 @@ If `yes`, sets the `--icons` option of `eza`, adding icons for files and folders Default: `no` +### `color-scale` + +```zsh +zstyle ':omz:plugins:eza' 'color-scale' all|age|size +``` + +Highlight levels of field(s) distinctly. Use comma(,) separated list of `all`, `age`, `size` + +Default: `none` + +### `color-scale-mode` + +```zsh +zstyle ':omz:plugins:eza' 'color-scale-mode' gradient|fixed +``` + +Choose the mode for highlighting: + +- `gradient` (default) -- gradient coloring +- `fixed` -- fixed coloring + +Default: `gradient` + ### `size-prefix` ```zsh diff --git a/plugins/eza/eza.plugin.zsh b/plugins/eza/eza.plugin.zsh index f25f1c30b..60ed1eb27 100644 --- a/plugins/eza/eza.plugin.zsh +++ b/plugins/eza/eza.plugin.zsh @@ -34,6 +34,14 @@ function _configure_eza() { if zstyle -t ':omz:plugins:eza' 'icons'; then _EZA_TAIL+=("--icons=auto") fi + zstyle -s ':omz:plugins:eza' 'color-scale' _val + if [[ $_val ]]; then + _EZA_TAIL+=("--color-scale=$_val") + fi + zstyle -s ':omz:plugins:eza' 'color-scale-mode' _val + if [[ $_val == (gradient|fixed) ]]; then + _EZA_TAIL+=("--color-scale-mode=$_val") + fi zstyle -s ':omz:plugins:eza' 'time-style' _val if [[ $_val ]]; then _EZA_TAIL+=("--time-style='$_val'")