comparison dot_config/nvim/init.lua @ 441:8b5c7359dd86

Add vsnip and path cmp plugins
author zegervdv <zegervdv@me.com>
date Fri, 27 Aug 2021 17:37:11 +0200
parents 84b4f33c0403
children e830ae093010
comparison
equal deleted inserted replaced
440:6503de68af7b 441:8b5c7359dd86
200 200
201 -- Completion/snippets/LSP 201 -- Completion/snippets/LSP
202 use { 'neovim/nvim-lspconfig' } 202 use { 'neovim/nvim-lspconfig' }
203 use { 203 use {
204 'hrsh7th/nvim-cmp', 204 'hrsh7th/nvim-cmp',
205 requires = { 'hrsh7th/cmp-buffer', 'hrsh7th/cmp-nvim-lsp' }, 205 requires = { 'hrsh7th/cmp-buffer', 'hrsh7th/cmp-nvim-lsp', 'hrsh7th/cmp-vsnip', 'hrsh7th/cmp-path' },
206 config = function() 206 config = function()
207 local cmp = require 'cmp' 207 local cmp = require 'cmp'
208 cmp.setup { 208 cmp.setup {
209 mapping = { 209 mapping = {
210 ['<C-p>'] = cmp.mapping.select_prev_item(), 210 ['<C-p>'] = cmp.mapping.select_prev_item(),
219 }, 219 },
220 }, 220 },
221 sources = { 221 sources = {
222 { name = 'buffer' }, 222 { name = 'buffer' },
223 { name = 'nvim_lsp' }, 223 { name = 'nvim_lsp' },
224 { name = 'vsnip' },
225 { name = 'path' },
224 }, 226 },
225 } 227 }
226 end, 228 end,
227 } 229 }
228 use { 230 use {