diff --git a/modules/programs/eza.nix b/modules/programs/eza.nix index 679f53499..f35912b8c 100644 --- a/modules/programs/eza.nix +++ b/modules/programs/eza.nix @@ -59,6 +59,14 @@ with lib; ''; }; + colors = mkOption { + type = types.enum [ null "auto" "always" "never" ]; + default = null; + description = '' + Use terminal colors in output ({option}`--color` argument). + ''; + }; + git = mkOption { type = types.bool; default = false; @@ -80,8 +88,9 @@ with lib; cfg.icons; in optionals (v != null) [ "--icons" v ]; - args = escapeShellArgs - (iconsOption ++ optional cfg.git "--git" ++ cfg.extraOptions); + args = escapeShellArgs (iconsOption + ++ optionals (cfg.colors != null) [ "--color" cfg.colors ] + ++ optional cfg.git "--git" ++ cfg.extraOptions); optionsAlias = optionalAttrs (args != "") { eza = "eza ${args}"; };