nvim: add some key mappings for LSP
This commit is contained in:
parent
c69624e00e
commit
d9df2ff4ac
|
@ -4,8 +4,10 @@ require('keymaps')
|
|||
use {
|
||||
'https://github.com/neovim/nvim-lspconfig',
|
||||
config = function()
|
||||
map('n', '<space>e', vim.diagnostic.open_float)
|
||||
map('n', '<f5>', vim.diagnostic.goto_prev)
|
||||
map('n', '<f6>', vim.diagnostic.goto_next)
|
||||
map('n', '<space>q', vim.diagnostic.setloclist)
|
||||
|
||||
-- Only map the following keys after the language server attaches to the
|
||||
-- current buffer
|
||||
|
|
|
@ -20,6 +20,7 @@ use {
|
|||
}
|
||||
use 'https://github.com/L3MON4D3/LuaSnip'
|
||||
|
||||
-- compile and install new plugins when this file is saved
|
||||
vim.cmd([[
|
||||
augroup packer_user_config
|
||||
autocmd!
|
||||
|
|
|
@ -36,4 +36,3 @@ vim.api.nvim_create_autocmd(
|
|||
command = 'lua remove_trailing_whitespace()'
|
||||
}
|
||||
)
|
||||
|
||||
|
|
Loading…
Reference in New Issue
Block a user