feat: added support for tabdrop (#2143)

This commit is contained in:
Ryan Koval
2022-09-04 14:47:25 -05:00
committed by GitHub
parent 19047b6b3c
commit 2b5060362b
4 changed files with 58 additions and 1 deletions

View File

@@ -68,6 +68,7 @@ local edit_buffer
do
local map = {
drop = "drop",
["tab drop"] = "tab drop",
edit = "buffer",
new = "sbuffer",
vnew = "vert sbuffer",
@@ -79,7 +80,7 @@ do
if command == nil then
error "There was no associated buffer command"
end
if command ~= "drop" then
if command ~= "drop" and command ~= "tab drop" then
vim.cmd(string.format("%s %d", command, bufnr))
else
vim.cmd(string.format("%s %s", command, vim.api.nvim_buf_get_name(bufnr)))