chore: refactor user modules
This commit is contained in:
19
users/modules/shell/zoxide.nix
Normal file
19
users/modules/shell/zoxide.nix
Normal file
@@ -0,0 +1,19 @@
|
||||
{
|
||||
lib,
|
||||
config,
|
||||
...
|
||||
}:
|
||||
with lib; let
|
||||
cfg = config.home.shell.zoxide;
|
||||
in {
|
||||
options.home.shell.zoxide = {
|
||||
enable = mkEnableOption "Enable zoxide";
|
||||
replaceCd = mkEnableOption "Replace cd with zoxide";
|
||||
};
|
||||
config.programs.zoxide = mkIf cfg.enable {
|
||||
inherit (cfg) enable;
|
||||
options = mkIf cfg.replaceCd [
|
||||
"--cmd cd"
|
||||
];
|
||||
};
|
||||
}
|
||||
Reference in New Issue
Block a user