aboutsummaryrefslogtreecommitdiff
path: root/modules/terminal/nixos/programs/eza.nix
blob: acdcbc25f55438a4658e8ae22e036817f3f6c101 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
{
  pkgs,
  lib,
  config,
  ...
}: let
  cfg = config.collinux.terminal.programs.eza;
in
  lib.mkIf cfg.enable {
    hjem.users."${config.collinux.user.name}" = {
      files =
        (lib.optionalAttrs config.collinux.terminal.shells.fish.enable {
          ".config/fish/conf.d/eza.fish".text = ''
            alias ls "eza -A -w 80 --group-directories-first -I '.git*'"
            alias tree "eza -T"
          '';
        })
        // (lib.optionalAttrs config.collinux.terminal.shells.fish.enable {
          ".config/bash/conf.d/eza.bash".text = ''
            alias ls="eza -A -w 80 --group-directories-first -I '.git*'"
            alias tree="eza -T"
          '';
        });

      packages = [pkgs.eza];
    };
  }