refactor(homeModules/cli): extract fzf to finder module=

This commit is contained in:
Mohammad Rafiq 2025-05-30 12:21:01 +08:00
parent 42cfd252f8
commit 9b6a92f9db
No known key found for this signature in database
3 changed files with 13 additions and 4 deletions

View file

@ -2,6 +2,7 @@
{
cli = {
shell = "zsh";
finder = "fzf";
screensaver.enable = true;
screensaver.timeout = "100";
screensaver.command = "cbonsai -S -w 0.1 -L 40 -M 2 -b 2";
@ -39,9 +40,5 @@
enable = true;
nix-direnv.enable = true;
};
fzf = {
enable = true;
enableZshIntegration = true;
};
};
}

View file

@ -7,6 +7,7 @@
{
options.cli = {
shell = lib.pantheon.mkStrOption;
finder = lib.pantheon.mkStrOption;
screensaver.enable = lib.mkEnableOption "";
screensaver.timeout = lib.pantheon.mkStrOption;
screensaver.command = lib.pantheon.mkStrOption;

View file

@ -0,0 +1,11 @@
{ config, lib, ... }:
{
config = lib.mkMerge [
(lib.mkIf (config.cli.finder == "fzf") {
programs.fzf = {
enable = true;
enableZshIntegration = lib.mkIf (config.cli.shell == "zsh") true;
};
})
];
}