code format cmp.lua
This commit is contained in:
parent
4240bd1bde
commit
6e3a2f931c
@ -38,8 +38,8 @@ return {
|
||||
cmp.setup({
|
||||
formatting = {
|
||||
format = require('lspkind').cmp_format({
|
||||
mode = 'symbol_text', -- show only symbol annotations
|
||||
maxwidth = 80, -- prevent the popup from showing more than provided characters (e.g 50 will not show more than 50 characters)
|
||||
mode = 'symbol_text', -- show only symbol annotations
|
||||
maxwidth = 80, -- prevent the popup from showing more than provided characters (e.g 50 will not show more than 50 characters)
|
||||
ellipsis_char = '...', -- when popup menu exceed maxwidth, the truncated part would show ellipsis_char instead (must define maxwidth first)
|
||||
})
|
||||
},
|
||||
@ -82,11 +82,13 @@ return {
|
||||
end,
|
||||
},
|
||||
sources = {
|
||||
{ name = 'luasnip', priority = 8 },
|
||||
{ name = 'nvim_lsp', priority = 7 },
|
||||
{ name = 'luasnip', priority = 8 },
|
||||
{ name = 'nvim_lsp', priority = 7 },
|
||||
{ name = 'nvim_lsp_signature_help', priority = 7 },
|
||||
{ name = 'treesitter', priority = 6 },
|
||||
{ name = 'buffer', priority = 5,
|
||||
{ name = 'treesitter', priority = 6 },
|
||||
{
|
||||
name = 'buffer',
|
||||
priority = 5,
|
||||
option = {
|
||||
get_bufnrs = function()
|
||||
local bufs = {}
|
||||
|
Loading…
x
Reference in New Issue
Block a user