From 02ac9387190de8c1470229d3a18d71b9bc688fab Mon Sep 17 00:00:00 2001 From: jaydamani Date: Wed, 31 Mar 2021 15:17:11 +0530 Subject: [PATCH] added new keybinds for bufferline --- lua/bufferline/lua.lua | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/lua/bufferline/lua.lua b/lua/bufferline/lua.lua index d3a8cf9..2f6d37d 100644 --- a/lua/bufferline/lua.lua +++ b/lua/bufferline/lua.lua @@ -57,6 +57,11 @@ local opt = {silent = true} vim.g.mapleader = " " +--command that adds new buffer and moves to it +vim.api.nvim_command "com -nargs=? -complete=file_in_path New badd | blast" +vim.api.nvim_set_keymap("n","",":New ", opt) +--removing a buffer +vim.api.nvim_set_keymap("n","",[[bdelete]], opt) -- tabnew and tabprev -vim.api.nvim_set_keymap("n", "tn", [[BufferLineCycleNext]], opt) -vim.api.nvim_set_keymap("n", "tp", [[BufferLineCyclePrev]], opt) +vim.api.nvim_set_keymap("n", "", [[BufferLineCycleNext]], opt) +vim.api.nvim_set_keymap("n", "", [[BufferLineCyclePrev]], opt)