Large rewrite, simplify keymapping, utilize as much keys from Lazy as
possible. Reduce manually setup plugins and utilize opts instead.
This commit is contained in:
parent
72eb62b9cb
commit
43020a4d12
17 changed files with 408 additions and 780 deletions
|
|
@ -7,59 +7,36 @@ return {
|
|||
dependencies = {
|
||||
"nvim-tree/nvim-web-devicons",
|
||||
},
|
||||
after = "nvim-lspconfig",
|
||||
config = function()
|
||||
require("lspsaga").setup({
|
||||
request_timeout = 750,
|
||||
symbol_in_winbar = {
|
||||
enable = false,
|
||||
},
|
||||
implement = {
|
||||
enable = false,
|
||||
},
|
||||
outline = {
|
||||
enable = false,
|
||||
win_width = 52,
|
||||
},
|
||||
ui = {
|
||||
border = "rounded",
|
||||
title = false,
|
||||
},
|
||||
code_action = {
|
||||
extend_gitsigns = true
|
||||
},
|
||||
hover = {
|
||||
jump_on_first_press = true
|
||||
},
|
||||
})
|
||||
|
||||
local keymaps = {
|
||||
n = {
|
||||
["K"] = {
|
||||
cmd = ":Lspsaga hover_doc<CR>"
|
||||
},
|
||||
["<leader>rn"] = {
|
||||
cmd = ":Lspsaga rename<CR>"
|
||||
},
|
||||
["gr"] = {
|
||||
cmd = ":Lspsaga finder<CR>"
|
||||
},
|
||||
["<leader>lt"] = {
|
||||
cmd = ":Lspsaga peek_type_definition<CR>"
|
||||
},
|
||||
["<leader>ld"] = {
|
||||
cmd = ":Lspsaga peek_definition<CR>"
|
||||
},
|
||||
["<leader>ca"] = {
|
||||
cmd = ":Lspsaga code_action<CR>"
|
||||
},
|
||||
["<leader>lc"] = {
|
||||
cmd = ":Lspsaga incoming_calls<CR>"
|
||||
},
|
||||
}
|
||||
}
|
||||
local utils = require("utils")
|
||||
utils.add_opts_to_all_mappings(keymaps, { silent = true })
|
||||
utils.add_keymaps(keymaps)
|
||||
end,
|
||||
opts = {
|
||||
request_timeout = 750,
|
||||
symbol_in_winbar = {
|
||||
enable = false,
|
||||
},
|
||||
implement = {
|
||||
enable = false,
|
||||
},
|
||||
outline = {
|
||||
enable = false,
|
||||
win_width = 52,
|
||||
},
|
||||
ui = {
|
||||
border = "rounded",
|
||||
title = false,
|
||||
},
|
||||
code_action = {
|
||||
extend_gitsigns = true
|
||||
},
|
||||
hover = {
|
||||
jump_on_first_press = true
|
||||
},
|
||||
},
|
||||
keys = {
|
||||
{ "K", ":Lspsaga hover_doc<CR>", silent = true, },
|
||||
{ "<leader>rn", ":Lspsaga rename<CR>", silent = true, },
|
||||
{ "gr", ":Lspsaga finder<CR>", silent = true, },
|
||||
{ "<leader>lt", ":Lspsaga peek_type_definition<CR>", silent = true, },
|
||||
{ "<leader>ld", ":Lspsaga peek_definition<CR>", silent = true, },
|
||||
{ "<leader>ca", ":Lspsaga code_action<CR>", silent = true, },
|
||||
{ "<leader>lc", ":Lspsaga incoming_calls<CR>", silent = true, },
|
||||
},
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue