Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

:Buffers doesn't let me select alternate buffer #1211

Closed
5 tasks done
paddor opened this issue Dec 30, 2020 · 2 comments
Closed
5 tasks done

:Buffers doesn't let me select alternate buffer #1211

paddor opened this issue Dec 30, 2020 · 2 comments

Comments

@paddor
Copy link

paddor commented Dec 30, 2020

I'm learning to work with buffers in Vim. Sometimes I open the Vim documentation in a split and later accidentally close the other window. I could do :vsp #, but I have a nice key binding for :Buffers. Unfortunately :Buffers won't let me select the bottom-most buffer in the list, which means I can't Ctrl-V to reopen in a split.

Any ideas?

@junegunn
Copy link
Owner

Most of the time, the bottom-most item is the current buffer, not the alternate buffer. We use --header-lines=1 option of fzf to disallow selecting the current buffer so it's easier to switch between two buffers.

What you're experiencing here is an exceptional case where the current buffer is an unlisted buffer (i.e. vim help) so it does not appear on the list, but we still apply --header-lines=1 when we shouldn't. I can fix this.

@paddor
Copy link
Author

paddor commented Dec 30, 2020

Thanks. It seems to work!

antoinemadec pushed a commit to antoinemadec/fzf.vim that referenced this issue Feb 28, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants