nixos-configs/homeManagerModules/shell/misc/default.nix
matt1432 66f415ff5f
All checks were successful
Discord / discord commits (push) Has been skipped
refactor: move common/home to nixosModules/shell
2024-11-22 17:58:24 -05:00

61 lines
1.1 KiB
Nix

self: {
config,
lib,
pkgs,
...
}: let
inherit (lib) mkIf;
cfg = config.programs.bash;
in {
config.programs = mkIf cfg.enable {
fzf = {
enable = true;
enableBashIntegration = true;
};
bash = {
sessionVariables = {
inherit (config.home.sessionVariables) RIPGREP_CONFIG_PATH;
};
shellAliases = {
rg = "rga";
cat = "bat ";
man = "BAT_THEME='default' batman ";
};
};
ripgrep = {
enable = true;
package = pkgs.ripgrep-all;
arguments = [
"--max-columns=150"
"--max-columns-preview"
"--hidden"
"--glob=!.git/*"
"--smart-case"
"--sort"
"path"
];
};
jq.enable = true;
htop.enable = true;
bat = {
enable = true;
config.theme = "dracula-bat";
themes.dracula-bat.src = self.scopedPackages.${pkgs.system}.dracula.bat;
extraPackages = builtins.attrValues {
inherit (pkgs.bat-extras) batman;
};
};
};
# For accurate stack trace
_file = ./default.nix;
}