nix-community.nixvim/plugins/by-name/netman/default.nix

34 lines
674 B
Nix
Raw Normal View History

{
lib,
config,
pkgs,
...
}:
2024-05-05 19:39:35 +02:00
{
options.plugins.netman = {
enable = lib.mkEnableOption "netman.nvim, a framework to access remote resources";
package = lib.mkPackageOption pkgs "netman.nvim" {
default = [
"vimPlugins"
"netman-nvim"
];
};
neoTreeIntegration = lib.mkEnableOption "support for netman as a neo-tree source";
};
2024-05-05 19:39:35 +02:00
config =
let
cfg = config.plugins.netman;
in
lib.mkIf cfg.enable {
2024-05-05 19:39:35 +02:00
extraPlugins = [ cfg.package ];
extraConfigLua = ''
require("netman")
'';
plugins.neo-tree.extraSources = lib.mkIf cfg.neoTreeIntegration [ "netman.ui.neo-tree" ];
};
}