refactor(nvim): improve trouble.nvim integration with quickfix
This commit is contained in:
parent
112c53d765
commit
4ba6f44dc1
@ -40,9 +40,17 @@ return {
|
|||||||
},
|
},
|
||||||
dependencies = { "nvim-tree/nvim-web-devicons" },
|
dependencies = { "nvim-tree/nvim-web-devicons" },
|
||||||
config = function()
|
config = function()
|
||||||
|
vim.api.nvim_create_autocmd("QuickFixCmdPost", {
|
||||||
|
callback = function ()
|
||||||
|
vim.cmd("Trouble quickfix")
|
||||||
|
end
|
||||||
|
})
|
||||||
require("trouble").setup({
|
require("trouble").setup({
|
||||||
auto_close = true,
|
auto_close = true,
|
||||||
position = "right",
|
position = "right",
|
||||||
|
action_keys = {
|
||||||
|
cancel = "q"
|
||||||
|
}
|
||||||
})
|
})
|
||||||
vim.api.nvim_create_autocmd("BufLeave", {
|
vim.api.nvim_create_autocmd("BufLeave", {
|
||||||
pattern = "*Trouble*",
|
pattern = "*Trouble*",
|
||||||
|
Loading…
Reference in New Issue
Block a user