added copilot

This commit is contained in:
Oliver Hartmann
2024-07-25 08:48:11 +02:00
parent a404864548
commit 0e0308a42d
2 changed files with 27 additions and 1 deletions

View File

@ -21,6 +21,7 @@ return {
{ 'hrsh7th/cmp-nvim-lsp-signature-help' },
{ 'chrisgrieser/cmp_yanky' },
{ 'p00f/clangd_extensions.nvim' },
{ 'zbirenbaum/copilot-cmp' },
{
'windwp/nvim-autopairs',
config = true,
@ -93,6 +94,7 @@ return {
end,
},
sources = {
{ name = "copilot", group_index = 2 },
{ name = 'codeium' },
{ name = 'luasnip', priority = 8 },
{
@ -161,7 +163,7 @@ return {
format = function(entry, vim_item)
local kind = lspkind.cmp_format({
mode = 'symbol',
symbol_map = { Codeium = '' },
symbol_map = { Codeium = '', Copilot = "", },
maxwidth = 50,
})(entry, vim_item)
local strings = vim.split(kind.kind, '%s', { trimempty = true })