LSP stuff

This commit is contained in:
Alexander Gehrke 2022-02-07 11:52:43 +01:00
parent ff5d0a1d45
commit 525dbfb3a7
7 changed files with 97 additions and 120 deletions

View file

@ -13,12 +13,19 @@ cmp.setup({
behavior = cmp.ConfirmBehavior.Replace,
select = true,
}),
['<Tab>'] = cmp.mapping(cmp.mapping.select_next_item(), { 'i', 's' })
['<Tab>'] = function(fallback)
if cmp.visible() then
cmp.select_next_item()
else
fallback()
end
end
},
sources = {
{ name = 'nvim_lsp' },
{ name = 'buffer' },
{ name = 'path' },
--{ name = 'buffer' },
{ name = 'vsnip' },
--{ name = 'path' },
}
})
local capabilities = vim.lsp.protocol.make_client_capabilities()