romgrk / barbar.nvim

The neovim tabline plugin.
2.16k stars 81 forks source link

Can't get BufferPickDelete working #554

Closed casey closed 4 months ago

casey commented 4 months ago

I'm trying to get BufferPickDelete working, but I'm getting some odd behavior.

I made a screen recording of the issue. In it, I open two text files, run BufferPickDelete, and press b to delete the second buffer. However, it doesn't remove it right away, and seems to be stuck waiting for input. I then press escape, at which point vim returns to normal, and the buffer is gone.

Am I messing up my config somehow?

: nvim --version                                                                                                                                                                                     ~
NVIM v0.9.5
Build type: Release
LuaJIT 2.1.1703358377

   system vimrc file: "$VIM/sysinit.vim"
  fall-back for $VIM: "/opt/homebrew/Cellar/neovim/0.9.5/share/nvim"

PS Thanks for barbar! I just replaced airline with barbar, and was able to replace my pretty extensive airline configuration with just require'barbar'.setup { auto_hide = 1, animation = false }, which is quite nice!

Iron-E commented 4 months ago

Thanks for the report! I'll take a look and see what might be up.

I'm glad you found it easy to setup :)

Iron-E commented 4 months ago

Hmm, I tried this command:

nvim --clean -u minimal.lua a b c d +BufferPickDelete

I was able to press a, b, c, and d to close the buffers. Can you try that and tell me if it works for you? If so it is likely something environment-related and we can go from there.

minimal.lua

-- or your install path
vim.opt.rtp:append '~/.local/share/nvim/lazy/barbar.nvim'

-- disable file icons so `nvim-web-devicons` isn't required
require'barbar'.setup { icons = { filetype = { enabled = false } } }
romgrk commented 4 months ago

I was able to reproduce with auto_hide, it should be fixed now.

casey commented 4 months ago

Nice, that fixed it, thank you so much!