mirror of
https://github.com/prurigro/darkcloud-nvimconfig.git
synced 2024-11-21 11:22:34 -05:00
Configure the nvim-cmp plugin priority and max item count
This commit is contained in:
parent
d997f77832
commit
75b1337274
1 changed files with 34 additions and 6 deletions
|
@ -48,12 +48,40 @@ if (vim.g.enablecompletion == 1) then
|
|||
}),
|
||||
|
||||
sources = cmp.config.sources({
|
||||
{ name = "buffer" },
|
||||
{ name = "treesitter" },
|
||||
{ name = "omni" },
|
||||
{ name = "async_path" },
|
||||
{ name = "tags", option = { current_buffer_only = true } },
|
||||
{ name = "snippy" },
|
||||
{
|
||||
name = "snippy",
|
||||
priority = 4
|
||||
},
|
||||
|
||||
{
|
||||
name = "async_path",
|
||||
priority = 3
|
||||
},
|
||||
|
||||
{
|
||||
name = "buffer",
|
||||
priority = 3,
|
||||
max_item_count = 5
|
||||
},
|
||||
|
||||
{
|
||||
name = "treesitter",
|
||||
priority = 2,
|
||||
max_item_count = 5
|
||||
},
|
||||
|
||||
{
|
||||
name = "omni",
|
||||
priority = 2,
|
||||
max_item_count = 5
|
||||
},
|
||||
|
||||
{
|
||||
name = "tags",
|
||||
priority = 1,
|
||||
max_item_count = 5,
|
||||
option = { current_buffer_only = true },
|
||||
},
|
||||
}),
|
||||
|
||||
enabled = function()
|
||||
|
|
Loading…
Reference in a new issue