blob: 85c9513e29fd35292b4344d25e4205b4b7750a8b (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
|
{
plugins = {
nvim-cmp = {
enable = true;
completion = {
completeopt = "menu,menuone,noinsert";
};
mapping = {
"<C-n>" = "cmp.mapping.select_next_item({ behavior = cmp.SelectBehavior.Insert })";
"<C-p>" = "cmp.mapping.select_prev_item({ behavior = cmp.SelectBehavior.Insert })";
"<C-b>" = "cmp.mapping.scroll_docs(-4)";
"<C-f>" = "cmp.mapping.scroll_docs(4)";
"<C-Space>" = "cmp.mapping.complete()";
"<C-e>" = "cmp.mapping.abort()";
"<CR>" = "cmp.mapping.confirm({ select = true })";
"<S-CR>" = "cmp.mapping.confirm({ behavior = cmp.ConfirmBehavior.Replace, select = true})";
};
snippet.expand = "luasnip";
sources = map (name: {inherit name;}) [
"nvim_lsp"
"luasnip"
"async_path"
"buffer"
];
};
};
}
|