neovim/plugins/ux/default.nix

24 lines
544 B
Nix

{ lib
, plugins
, hop-nvim
, nvim-orgmode
, nvim-colorizer
, org-bullets-nvim
, enableOrgMode ? false
, ...
}:
let
inherit (builtins) readFile;
orgmodeSettings = lib.toLua (lib.attrByPath [ "orgmode" "settings" ] { } plugins);
in
{
luaConfig = readFile ./hop-nvim.lua
+ lib.optional enableOrgMode (readFile (lib.substituteAll { src = ./nvim-orgmode.lua; inherit orgmodeSettings; }))
+ readFile ./nvim-colorizer.lua;
plugins = [ hop-nvim nvim-colorizer ]
++ lib.optional enableOrgMode [ nvim-orgmode org-bullets-nvim ];
}