mirror of
https://github.com/NotAShelf/neovim-flake.git
synced 2024-12-24 19:19:48 +01:00
24 lines
497 B
Nix
24 lines
497 B
Nix
|
{
|
||
|
pkgs,
|
||
|
config,
|
||
|
lib,
|
||
|
...
|
||
|
}:
|
||
|
with lib;
|
||
|
with builtins; let
|
||
|
cfg = config.vim.lsp;
|
||
|
in {
|
||
|
config = mkIf (cfg.enable && cfg.lightbulb.enable) {
|
||
|
vim.startPlugins = ["nvim-lightbulb"];
|
||
|
|
||
|
vim.configRC.lightbulb = nvim.dag.entryAnywhere ''
|
||
|
autocmd CursorHold,CursorHoldI * lua require'nvim-lightbulb'.update_lightbulb()
|
||
|
'';
|
||
|
|
||
|
vim.luaConfigRC.lightbulb = nvim.dag.entryAnywhere ''
|
||
|
-- Enable trouble diagnostics viewer
|
||
|
require'nvim-lightbulb'.setup()
|
||
|
'';
|
||
|
};
|
||
|
}
|