2024-04-14 14:49:16 +02:00
|
|
|
{
|
|
|
|
config,
|
|
|
|
lib,
|
|
|
|
...
|
|
|
|
}: let
|
|
|
|
inherit (lib.modules) mkIf;
|
2024-04-14 15:18:50 +02:00
|
|
|
inherit (lib.nvim.dag) entryAnywhere;
|
2024-04-18 21:16:38 +02:00
|
|
|
inherit (lib.nvim.lua) toLuaObject;
|
2024-04-14 14:49:16 +02:00
|
|
|
|
|
|
|
cfg = config.vim.filetree.neo-tree;
|
|
|
|
in {
|
|
|
|
config = mkIf cfg.enable {
|
2024-04-14 15:18:50 +02:00
|
|
|
vim = {
|
|
|
|
startPlugins = [
|
|
|
|
# dependencies
|
|
|
|
"plenary-nvim" # commons library
|
|
|
|
"image-nvim" # optional for image previews
|
|
|
|
"nui-nvim" # ui library
|
|
|
|
# neotree
|
|
|
|
"neo-tree-nvim"
|
|
|
|
];
|
|
|
|
|
2024-04-18 21:16:38 +02:00
|
|
|
luaConfigRC.neo-tree = entryAnywhere ''
|
2024-04-14 15:18:50 +02:00
|
|
|
require("neo-tree").setup(${toLuaObject cfg.setupOpts})
|
|
|
|
'';
|
|
|
|
};
|
2024-04-14 14:49:16 +02:00
|
|
|
};
|
|
|
|
}
|