From e3cfce0dd56c22ba719498ce7ed4cb97808c8fdb Mon Sep 17 00:00:00 2001 From: Pandu POLUAN Date: Wed, 28 Feb 2024 10:55:37 +0700 Subject: [PATCH] Add `header` config knob --- plugins/eza/README.md | 11 +++++++++++ plugins/eza/eza.plugin.zsh | 3 +++ 2 files changed, 14 insertions(+) diff --git a/plugins/eza/README.md b/plugins/eza/README.md index 081697320..26f11bae1 100644 --- a/plugins/eza/README.md +++ b/plugins/eza/README.md @@ -25,6 +25,17 @@ If `true`, directories will be grouped first. Default: `false` +### `header` + +```zsh +zstyle ':omz:plugins:eza' 'header' $BOOL +``` + +If `true`, always add `-h` flag to add a header row for each column. + +Default: `false` + + ### `showgroup` ```zsh diff --git a/plugins/eza/eza.plugin.zsh b/plugins/eza/eza.plugin.zsh index edb4128cd..8f4837803 100644 --- a/plugins/eza/eza.plugin.zsh +++ b/plugins/eza/eza.plugin.zsh @@ -12,6 +12,9 @@ function _configure_eza() { if zstyle -T ':omz:plugins:eza' 'showgroup'; then _EZA_HEAD+=("g") fi + if zstyle -t ':omz:plugins:eza' 'header'; then + _EZA_HEAD+=("h") + fi # Get the tail long-options if zstyle -t ':omz:plugins:eza' 'dirs-first'; then _EZA_TAIL+=("--group-directories-first")