nvf/modules/lsp/nvim-code-action-menu.nix

25 lines
413 B
Nix
Raw Normal View History

{
pkgs,
config,
lib,
...
}:
with lib;
with builtins; let
cfg = config.vim.lsp;
in {
options.vim.lsp = {
nvimCodeActionMenu = {
enable = mkEnableOption "nvim code action menu";
};
};
config = mkIf (cfg.enable && cfg.nvimCodeActionMenu.enable) {
vim.startPlugins = ["nvim-code-action-menu"];
vim.nnoremap = {
"<silent><leader>ca" = ":CodeActionMenu<CR>";
};
};
}