22 lines
609 B
Nix
22 lines
609 B
Nix
{ lib
|
|
, plugins ? { }
|
|
, nvim-tree-lua
|
|
, telescope-nvim
|
|
, telescope-live-grep-args-nvim
|
|
, ...
|
|
}:
|
|
|
|
let
|
|
inherit (builtins) readFile;
|
|
|
|
nvimTreeLuaSettings = lib.toLua (lib.attrByPath [ "nvimTree" "settings" ] { } plugins);
|
|
telescopeSettings = lib.toLua (lib.attrByPath [ "telescope" "settings" ] { } plugins);
|
|
in
|
|
{
|
|
luaConfig =
|
|
(readFile (lib.substituteAll { src = ./nvim-tree.lua; inherit nvimTreeLuaSettings; }))
|
|
+ (readFile (lib.substituteAll { src = ./telescope-nvim.lua; inherit telescopeSettings; }));
|
|
|
|
plugins = [ nvim-tree-lua ]
|
|
++ [ telescope-nvim telescope-live-grep-args-nvim ];
|
|
}
|