Replace lspsaga with my fork of lspsaga which contains more options for the winbar which makes it easier to integrate it with lualine, which I've also done here. Additionally, set cmdheight=0, and refactor some calls to add_keymaps.
This commit is contained in:
parent
fc96fc96fc
commit
b9ffc6647e
6 changed files with 119 additions and 21 deletions
65
nvim/lua/plugs/lspsaga.lua
Normal file
65
nvim/lua/plugs/lspsaga.lua
Normal file
|
|
@ -0,0 +1,65 @@
|
|||
return {
|
||||
"LarssonMartin1998/lspsaga.nvim",
|
||||
branch = "improved_winbar",
|
||||
dependencies = {
|
||||
"nvim-treesitter/nvim-treesitter",
|
||||
"nvim-tree/nvim-web-devicons",
|
||||
},
|
||||
config = function()
|
||||
require("lspsaga").setup({
|
||||
symbol_in_winbar = {
|
||||
enable = false,
|
||||
separator = " › ",
|
||||
hide_keyword = true,
|
||||
ignore_patterns = nil,
|
||||
show_file = true,
|
||||
folder_level = 3,
|
||||
color_mode = true,
|
||||
dely = 300,
|
||||
show_nodes = true,
|
||||
max_nodes = 3,
|
||||
},
|
||||
implement = {
|
||||
enable = false,
|
||||
},
|
||||
})
|
||||
|
||||
require("utils").add_keymaps({
|
||||
n = {
|
||||
["<F2>"] = {
|
||||
cmd = ":Lspsaga diagnostic_jump_next<CR>"
|
||||
},
|
||||
["<S-F2>"] = {
|
||||
cmd = ":Lspsaga diagnostic_jump_prev<CR>"
|
||||
},
|
||||
["K"] = {
|
||||
cmd = ":Lspsaga hover_doc<CR>"
|
||||
},
|
||||
["<leader>lo"] = {
|
||||
cmd = ":Lspsaga outline<CR>"
|
||||
},
|
||||
["<leader>lr"] = {
|
||||
cmd = ":Lspsaga rename<CR>"
|
||||
},
|
||||
["<leader>h"] = {
|
||||
cmd = ":Lspsaga term_toggle<CR>"
|
||||
},
|
||||
["<leader>lf"] = {
|
||||
cmd = ":Lspsaga finder<CR>"
|
||||
},
|
||||
["<leader>lpt"] = {
|
||||
cmd = ":Lspsaga peek_type_definition<CR>"
|
||||
},
|
||||
["<leader>lph"] = {
|
||||
cmd = ":Lspsaga peek_definition<CR>"
|
||||
},
|
||||
["<leader>ca"] = {
|
||||
cmd = ":Lspsaga code_action<CR>"
|
||||
},
|
||||
["<leader>lc"] = {
|
||||
cmd = ":Lspsaga incoming_calls<CR>"
|
||||
},
|
||||
}
|
||||
})
|
||||
end,
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue