From 6cee271f9bf961213622714e8ee7728c4fc4463b Mon Sep 17 00:00:00 2001 From: "Juan J. Martinez" Date: Mon, 6 Dec 2021 15:45:38 +0000 Subject: Only in current buffer --- metals.vim | 30 +++++++++++++++--------------- 1 file changed, 15 insertions(+), 15 deletions(-) diff --git a/metals.vim b/metals.vim index 253e351..73299d7 100644 --- a/metals.vim +++ b/metals.vim @@ -20,23 +20,23 @@ EOF " nvim-lsp mappings for metals " function! MetalsMapKeys() abort - nnoremap lua vim.lsp.buf.definition() - nnoremap K lua vim.lsp.buf.hover() - nnoremap gi lua vim.lsp.buf.implementation() - nnoremap gr lua vim.lsp.buf.references() - nnoremap gds lua vim.lsp.buf.document_symbol() - nnoremap gws lua vim.lsp.buf.workspace_symbol() - nnoremap gsh lua vim.lsp.buf.signature_help() - nnoremap rn lua vim.lsp.buf.rename() - nnoremap F lua vim.lsp.buf.formatting() - nnoremap ca lua vim.lsp.buf.code_action() - nnoremap ws lua require'metals'.worksheet_hover() - nnoremap a lua require'metals'.open_all_diagnostics() + nnoremap lua vim.lsp.buf.definition() + nnoremap K lua vim.lsp.buf.hover() + nnoremap gi lua vim.lsp.buf.implementation() + nnoremap gr lua vim.lsp.buf.references() + nnoremap gds lua vim.lsp.buf.document_symbol() + nnoremap gws lua vim.lsp.buf.workspace_symbol() + nnoremap gsh lua vim.lsp.buf.signature_help() + nnoremap rn lua vim.lsp.buf.rename() + nnoremap F lua vim.lsp.buf.formatting() + nnoremap ca lua vim.lsp.buf.code_action() + nnoremap ws lua require'metals'.worksheet_hover() + nnoremap a lua require'metals'.open_all_diagnostics() " diagnostic navigation - nnoremap d lua vim.diagnostic.open_float(0, {scope = "line"}) - nnoremap dn lua vim.diagnostic.goto_next() - nnoremap dp lua vim.diagnostic.goto_next() + nnoremap d lua vim.diagnostic.open_float(0, {scope = "line"}) + nnoremap dn lua vim.diagnostic.goto_next() + nnoremap dp lua vim.diagnostic.goto_next() endfunction if has('nvim-0.5') -- cgit v1.2.3