Skip to content

Commit

Permalink
feat: lsd custom aliases
Browse files Browse the repository at this point in the history
  • Loading branch information
khaneliman committed Oct 13, 2023
1 parent 0bb294f commit a4ceeb3
Showing 1 changed file with 10 additions and 2 deletions.
12 changes: 10 additions & 2 deletions modules/home/tools/lsd/default.nix
Original file line number Diff line number Diff line change
@@ -1,24 +1,30 @@
{ config
, lib
, options
, pkgs
, ...
}:
let
inherit (lib) mkIf;
inherit (lib.internal) mkBoolOpt;

cfg = config.khanelinix.tools.lsd;

aliases = {

ls = "${pkgs.lsd}/bin/lsd -al";
lt = "${pkgs.lsd}/bin/lsd --tree";
llt = "${pkgs.lsd}/bin/lsd -l --tree";
};
in
{
options.khanelinix.tools.lsd = {
enable = mkBoolOpt false "Whether or not to enable lsd.";
};

config = mkIf cfg.enable {
# TODO: fix aliases
programs.lsd = {
enable = true;
enableAliases = true;

settings = {
blocks = [ "permission" "user" "group" "size" "date" "name" ];
Expand All @@ -45,5 +51,7 @@ in
# total-size = true;
};
};

home.shellAliases = aliases;
};
}

0 comments on commit a4ceeb3

Please sign in to comment.