home: vim: completion: use better order

This commit is contained in:
Bruno BELANYI 2022-03-06 11:53:48 +01:00
parent aac464c9a2
commit 5b8e410596

View file

@ -9,10 +9,21 @@ cmp.setup({
entries = "native", entries = "native",
}, },
sources = { sources = {
{ name = "buffer" }, { name = "path", priority_weight = 110 },
{ name = "nvim_lsp" }, { name = "nvim_lsp", priority_weight = 100 },
{ name = "nvim_lua" }, { name = "nvim_lua", priority_weight = 90 },
{ name = "path" }, { name = "buffer", priority_weight = 50 },
},
sorting = {
comparators = {
cmp.config.compare.offset,
cmp.config.compare.exact,
cmp.config.compare.score,
cmp.config.compare.kind,
cmp.config.compare.sort_text,
cmp.config.compare.length,
cmp.config.compare.order,
},
}, },
}) })
EOF EOF