diff options
Diffstat (limited to 'modules/programs/kakoune.nix')
-rw-r--r-- | modules/programs/kakoune.nix | 17 |
1 files changed, 16 insertions, 1 deletions
diff --git a/modules/programs/kakoune.nix b/modules/programs/kakoune.nix index 3c2349151c1..6db311a1376 100644 --- a/modules/programs/kakoune.nix +++ b/modules/programs/kakoune.nix @@ -489,6 +489,10 @@ let }; }; + kakouneWithPlugins = pkgs.wrapKakoune pkgs.kakoune-unwrapped { + configure = { plugins = cfg.plugins; }; + }; + configFile = let wrapOptions = with cfg.config.wrapLines; concatStrings [ @@ -634,11 +638,22 @@ in { <filename>~/.config/kak/kakrc</filename>. ''; }; + + plugins = mkOption { + type = with types; listOf package; + default = [ ]; + example = literalExample "[ pkgs.kakounePlugins.kak-fzf ]"; + description = '' + List of kakoune plugins to install. To get a list of + supported plugins run: + <command>nix-env -f '<nixpkgs>' -qaP -A kakounePlugins</command>. + ''; + }; }; }; config = mkIf cfg.enable { - home.packages = [ pkgs.kakoune ]; + home.packages = [ kakouneWithPlugins ]; xdg.configFile."kak/kakrc".source = configFile; }; } |