removed custom cmp lsp setup, didnt play well with lspinstall.
This commit is contained in:
		
							parent
							
								
									c52ecd2166
								
							
						
					
					
						commit
						1796fdbbf9
					
				
					 1 changed files with 0 additions and 15 deletions
				
			
		| 
						 | 
				
			
			@ -1,22 +1,7 @@
 | 
			
		|||
--configure nvim-cmp for use with lsp and luasnip.
 | 
			
		||||
 | 
			
		||||
-- Add additional capabilities supported by nvim-cmp
 | 
			
		||||
local capabilities = vim.lsp.protocol.make_client_capabilities()
 | 
			
		||||
capabilities = require('cmp_nvim_lsp').update_capabilities(capabilities)
 | 
			
		||||
 | 
			
		||||
local luasnip = require 'luasnip'
 | 
			
		||||
 | 
			
		||||
local lspconfig = require('lspconfig')
 | 
			
		||||
 | 
			
		||||
-- Enable some language servers with the additional completion capabilities offered by nvim-cmp
 | 
			
		||||
local servers = {'texlab', 'rust_analyzer', 'pyright'}
 | 
			
		||||
for _, lsp in ipairs(servers) do
 | 
			
		||||
	lspconfig[lsp].setup {
 | 
			
		||||
		-- on_attach = my_custom_on_attach,
 | 
			
		||||
		capabilities = capabilities,
 | 
			
		||||
	}
 | 
			
		||||
end
 | 
			
		||||
 | 
			
		||||
-- Set completeopt to have a better completion experience
 | 
			
		||||
vim.o.completeopt='menu,menuone,preview,noinsert'
 | 
			
		||||
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue