summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJackson Taylor <jtaylor@classicalconversations.com>2023-06-13 15:01:36 -0400
committerJackson Taylor <jtaylor@classicalconversations.com>2023-06-13 15:01:36 -0400
commit07fc6b6714d462ebed89708b940fe3714e36fe86 (patch)
treed17202c091eb9d390d4bcb0dbf8e5ec7713ceeca
parenta635a721247fd0f007ec4d741f7655166818cf5b (diff)
Add bufkill package
Allows you to close a buffer without losing your window placement (splits)
-rw-r--r--after/plugin/which-key.lua3
-rw-r--r--lua/jacksontaylorxyz/packer.lua1
2 files changed, 3 insertions, 1 deletions
diff --git a/after/plugin/which-key.lua b/after/plugin/which-key.lua
index be6392e..27ef84c 100644
--- a/after/plugin/which-key.lua
+++ b/after/plugin/which-key.lua
@@ -34,7 +34,8 @@ function whichkey_setup()
local mappings = {
b = {
name = "Buffer",
- c = { "<Cmd>bp|bd #<Cr>", "Close current buffer" },
+ -- c = { "<Cmd>bp|bd #<Cr>", "Close current buffer" },
+ c = { "<Cmd>BD<Cr>", "Close current buffer" },
D = { "<Cmd>%bd|e#|bd#<Cr>", "Delete all buffers" },
},
diff --git a/lua/jacksontaylorxyz/packer.lua b/lua/jacksontaylorxyz/packer.lua
index aad6072..988ea26 100644
--- a/lua/jacksontaylorxyz/packer.lua
+++ b/lua/jacksontaylorxyz/packer.lua
@@ -19,6 +19,7 @@ return require('packer').startup(function(use)
}
use 'nvim-tree/nvim-web-devicons' -- Icons for other plugins
use 'preservim/tagbar' -- Ctags but in memory. Typescript does not work very well with exuberant ctags. Might work better with Universal ctags
+ use 'qpkorr/vim-bufkill' -- Closes buffer, but doesn't effect the window placement (splits)
use { -- Highlights TODO comments
"folke/todo-comments.nvim",
requires = "nvim-lua/plenary.nvim",