From 3429ad877b85885782eb1762af98d64a5a01d409 Mon Sep 17 00:00:00 2001 From: Folke Lemaitre Date: Sat, 31 Dec 2022 18:22:16 +0100 Subject: [PATCH] feat(editor): added mini.bufremove --- lazy-lock.json | 1 + lua/plugins/editor.lua | 22 ++++++++++++++++++++++ 2 files changed, 23 insertions(+) diff --git a/lazy-lock.json b/lazy-lock.json index e8e63d79..680aa640 100644 --- a/lazy-lock.json +++ b/lazy-lock.json @@ -14,6 +14,7 @@ "lualine.nvim": { "branch": "master", "commit": "32a7382a75a52e8ad05f4cec7eeb8bbfbe80d461" }, "mason-lspconfig.nvim": { "branch": "main", "commit": "aa25b4153d2f2636c3b3a8c8360349d2b29e7ae3" }, "mason.nvim": { "branch": "main", "commit": "1592493e3406c271e9128b4d424731e25f1ff2a1" }, + "mini.bufremove": { "branch": "main", "commit": "96c2a7f3e7d079639a0e23d2fc0d4585e5d02dfd" }, "mini.comment": { "branch": "main", "commit": "e5294cc3e75bafb2369f235d31a98b01a9cc67ad" }, "mini.pairs": { "branch": "main", "commit": "fec9aba50912d8c3d92d07d6a77952de84f8d7ad" }, "neo-tree.nvim": { "branch": "v2.x", "commit": "3b41f0d17139bb156f1acd907608f63e0e307caf" }, diff --git a/lua/plugins/editor.lua b/lua/plugins/editor.lua index 3dd093a1..e3205c25 100644 --- a/lua/plugins/editor.lua +++ b/lua/plugins/editor.lua @@ -43,6 +43,7 @@ return { wk.register({ f = { name = "+file" }, g = { name = "+git" }, + b = { name = "+buffer" }, }, { prefix = "" }) end, }, @@ -87,4 +88,25 @@ return { }, }, }, + + -- buffer remove + { + "echasnovski/mini.bufremove", + keys = { + { + "bd", + function() + require("mini.bufremove").delete(0, false) + end, + desc = "Delete Buffer", + }, + { + "bD", + function() + require("mini.bufremove").delete(0, true) + end, + desc = "Delete Buffer (Force)", + }, + }, + }, }