1
0
Fork 0
mirror of https://github.com/NotAShelf/neovim-flake.git synced 2024-12-27 10:39:47 +01:00
neovim-flake/modules/assistant/tabnine/config.nix
2023-03-31 05:20:35 +03:00

23 lines
552 B
Nix

{
config,
lib,
...
}:
with lib;
with builtins; let
cfg = config.vim.assistant.tabnine;
in {
config = mkIf cfg.enable {
vim.startPlugins = ["tabnine-nvim"];
vim.luaConfigRC.tabnine-nvim = nvim.dag.entryAnywhere ''
require('tabnine').setup({
disable_auto_comment = ${boolToString cfg.disable_auto_comment},
accept_keymap = ${cfg.accept_keymap},
dismiss_keymap = ${cfg.dismiss_keymap},
debounce_ms = ${cfg.debounce_ms},
execlude_filetypes = ${cfg.execlude_filetypes},
})
'';
};
}