nvim: Fix mapping incompabitility

Fixed keymap incompabitility introduced with switching to lspsaga code
actions. It used `gc` for normal/visual mode code actions, which I already
make use of for toggling comments in code.

Switched to `ca` instead.
This commit is contained in:
Marty Oehme 2021-03-22 21:16:54 +01:00
parent bcd90e7048
commit d880893e21
Signed by: Marty
GPG key ID: B7538B8F50A1C800

View file

@ -8,9 +8,9 @@ local on_attach = function(_, _)
{noremap = true, silent = true}) {noremap = true, silent = true})
vim.api.nvim_set_keymap("n", "gd", "<cmd>lua require'lspsaga.provider'.preview_definition()<CR>", vim.api.nvim_set_keymap("n", "gd", "<cmd>lua require'lspsaga.provider'.preview_definition()<CR>",
{noremap = true, silent = true}) {noremap = true, silent = true})
vim.api.nvim_set_keymap("n", "gc", "<cmd>lua require 'lspsaga.codeaction'.code_action()<CR>", vim.api.nvim_set_keymap("n", "ca", "<cmd>lua require 'lspsaga.codeaction'.code_action()<CR>",
{noremap = true, silent = true}) {noremap = true, silent = true})
vim.api.nvim_set_keymap("v", "gc", "<cmd>'<,'>lua require 'lspsaga.codeaction'.range_code_action()<CR>", vim.api.nvim_set_keymap("v", "ca", "<cmd>'<,'>lua require 'lspsaga.codeaction'.range_code_action()<CR>",
{noremap = true, silent = true}) {noremap = true, silent = true})
vim.api.nvim_set_keymap("n", "K", "<cmd>lua require('lspsaga.hover').render_hover_doc()<CR>", vim.api.nvim_set_keymap("n", "K", "<cmd>lua require('lspsaga.hover').render_hover_doc()<CR>",
{noremap = true, silent = true}) {noremap = true, silent = true})