plugins/nvim-cmp: refactoring (init filetype and cmdline options)

This commit is contained in:
Gaetan Lepage 2024-02-03 23:22:06 +01:00 committed by Gaétan Lepage
parent 22b587f3dc
commit a61c8fbc3d
26 changed files with 1166 additions and 948 deletions

View file

@ -100,37 +100,40 @@
enable = true;
};
nvim-cmp = {
formatting = {
format = ''
require("lspkind").cmp_format({
mode="symbol",
maxwidth = 50,
ellipsis_char = "..."
})
'';
};
autoEnableSources = true;
snippet = {
expand.__raw = ''
function(args)
require("luasnip").lsp_expand(args.body)
end
'';
};
cmp = {
enable = true;
sources = [
{name = "nvim_lsp";}
{
name = "luasnip";
option = {
show_autosnippets = true;
};
}
{name = "path";}
{name = "buffer";}
];
autoEnableSources = true;
settings = {
formatting = {
format = ''
require("lspkind").cmp_format({
mode="symbol",
maxwidth = 50,
ellipsis_char = "..."
})
'';
};
snippet = {
expand = ''
function(args)
require("luasnip").lsp_expand(args.body)
end
'';
};
sources = [
{name = "nvim_lsp";}
{
name = "luasnip";
option = {
show_autosnippets = true;
};
}
{name = "path";}
{name = "buffer";}
];
};
};
barbar.enable = true;
};