Formatting: remap.lua

This commit is contained in:
2025-12-22 16:19:24 +09:00
parent b28cbfc2c1
commit e4e728eb5b
+3 -2
View File
@@ -98,7 +98,8 @@ vim.api.nvim_create_autocmd("FileType", {
callback = function() callback = function()
vim.api.nvim_buf_set_keymap(0, "n", "q", ":q<cr>", { desc = "Close current QuickFix buffer" }) vim.api.nvim_buf_set_keymap(0, "n", "q", ":q<cr>", { desc = "Close current QuickFix buffer" })
vim.api.nvim_buf_set_keymap(0, "n", "<Escape>", ":q<cr>", { desc = "Close current QuickFix buffer" }) vim.api.nvim_buf_set_keymap(0, "n", "<Escape>", ":q<cr>", { desc = "Close current QuickFix buffer" })
vim.api.nvim_buf_set_keymap(0, "n", "<leader><CR>", "<C-w><Enter><C-w>L", { desc = "Open quick fix element in vertical split" }) vim.api.nvim_buf_set_keymap(0, "n", "<leader><CR>", "<C-w><Enter><C-w>L",
{ desc = "Open quick fix element in vertical split" })
end, end,
group = qf_group group = qf_group
}) })
@@ -120,7 +121,7 @@ function AddLocListEntry()
text = vim.api.nvim_get_current_line(), text = vim.api.nvim_get_current_line(),
type = "I", type = "I",
} }
vim.fn.setloclist(0, {new_entry}, "a") vim.fn.setloclist(0, { new_entry }, "a")
if not IsLocListOpen() then if not IsLocListOpen() then
vim.cmd("lopen") vim.cmd("lopen")
vim.cmd.wincmd("p") vim.cmd.wincmd("p")