Add bufdelete
This commit is contained in:
@@ -0,0 +1,6 @@
|
||||
vim.keymap.set(
|
||||
"n",
|
||||
"<leader>q",
|
||||
":Bwipeout<CR>",
|
||||
{ remap = false, silent = true, }
|
||||
)
|
||||
@@ -23,9 +23,11 @@ local ft_map = {
|
||||
fugitive = false,
|
||||
}
|
||||
|
||||
require("bufferline").setup(
|
||||
{
|
||||
require("bufferline").setup({
|
||||
options = {
|
||||
close_command = "Bwipeout %d",
|
||||
right_mouse_command = nil,
|
||||
middle_mouse_command = "Bwipeout %d",
|
||||
diagnostics = "nvim_lsp",
|
||||
diagnostics_update_in_insert = false,
|
||||
custom_filter = function (buf, _)
|
||||
@@ -59,5 +61,4 @@ require("bufferline").setup(
|
||||
},
|
||||
sort_by = "id",
|
||||
},
|
||||
}
|
||||
)
|
||||
})
|
||||
|
||||
@@ -48,8 +48,6 @@ vim.keymap.set("n", "<C-s>", ":w<CR>", opts)
|
||||
-- Cycle buffers
|
||||
vim.keymap.set("n", "<C-End>", ":BufferLineCycleNext<CR>", opts)
|
||||
vim.keymap.set("n", "<C-Home>", ":BufferLineCyclePrev<CR>", opts)
|
||||
-- Close buffer without closing window
|
||||
vim.keymap.set("n", "<leader>q", ":bp<bar>sp<bar>bn<bar>bd<CR>", opts)
|
||||
|
||||
--- General mappings ---
|
||||
-- yank/put using named register
|
||||
|
||||
@@ -191,6 +191,10 @@ local plugins = {
|
||||
"RubixDev/mason-update-all",
|
||||
config = function () require("config.mason_update_all") end,
|
||||
},
|
||||
{
|
||||
"famiu/bufdelete.nvim",
|
||||
config = function () require("config.bufdelete") end,
|
||||
},
|
||||
}
|
||||
|
||||
local opts = {}
|
||||
|
||||
Reference in New Issue
Block a user