|
@@ -82,15 +82,16 @@ function on_attach(client, bufnr)
|
|
|
|
|
|
-- LSP-specific mappings
|
|
-- LSP-specific mappings
|
|
vim.keymap.set('n', 'gD', '<cmd>lua vim.lsp.buf.declaration()<CR>', opts)
|
|
vim.keymap.set('n', 'gD', '<cmd>lua vim.lsp.buf.declaration()<CR>', opts)
|
|
- vim.keymap.set('n', 'gd', '<cmd>lua vim.lsp.buf.definition()<CR>', opts)
|
|
|
|
|
|
+ vim.keymap.set('n', 'gd', '<cmd>Telescope lsp_definitions<CR>', opts)
|
|
vim.keymap.set('n', 'K', '<cmd>lua vim.lsp.buf.hover()<CR>', opts)
|
|
vim.keymap.set('n', 'K', '<cmd>lua vim.lsp.buf.hover()<CR>', opts)
|
|
- vim.keymap.set('n', 'gi', '<cmd>lua vim.lsp.buf.implementation()<CR>', opts)
|
|
|
|
|
|
+ vim.keymap.set('n', 'gi', '<cmd>Telescope lsp_implementations<CR>', opts)
|
|
vim.keymap.set({'n', 'i'}, '<C-k>', '<cmd>lua vim.lsp.buf.signature_help()<CR>', opts)
|
|
vim.keymap.set({'n', 'i'}, '<C-k>', '<cmd>lua vim.lsp.buf.signature_help()<CR>', opts)
|
|
- vim.keymap.set('n', '<space>D', '<cmd>lua vim.lsp.buf.type_definition()<CR>', opts)
|
|
|
|
|
|
+ vim.keymap.set('n', '<space>D', '<cmd>Telescope lsp_type_definitions<CR>', opts)
|
|
vim.keymap.set('n', '<space>rn', '<cmd>lua vim.lsp.buf.rename()<CR>', opts)
|
|
vim.keymap.set('n', '<space>rn', '<cmd>lua vim.lsp.buf.rename()<CR>', opts)
|
|
vim.keymap.set('n', '<space>ca', '<cmd>lua vim.lsp.buf.code_action()<CR>', opts)
|
|
vim.keymap.set('n', '<space>ca', '<cmd>lua vim.lsp.buf.code_action()<CR>', opts)
|
|
- vim.keymap.set('v', '<space>ca', '<cmd>lua vim.lsp.buf.range_code_action()<CR><ESC>', opts)
|
|
|
|
|
|
+ vim.keymap.set('v', '<space>ca', '<cmd>lua vim.lsp.buf.range_code_action()<CR>', opts)
|
|
vim.keymap.set('n', 'gr', '<cmd>Telescope lsp_references<CR>', opts)
|
|
vim.keymap.set('n', 'gr', '<cmd>Telescope lsp_references<CR>', opts)
|
|
vim.keymap.set('n', '<Leader>fs', '<cmd>Telescope lsp_document_symbols<CR>', opts)
|
|
vim.keymap.set('n', '<Leader>fs', '<cmd>Telescope lsp_document_symbols<CR>', opts)
|
|
vim.keymap.set('n', '<Leader>fr', '<cmd>Telescope resume<CR>', opts)
|
|
vim.keymap.set('n', '<Leader>fr', '<cmd>Telescope resume<CR>', opts)
|
|
|
|
+ vim.keymap.set('n', '<Leader>fp', '<cmd>Telescope pickers<CR>', opts)
|
|
end
|
|
end
|