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

no-neck-pain exits neovim when closing a tab page with no-neck-pane enabled #370

Closed
lorentzforces opened this issue Jun 22, 2024 · 2 comments · Fixed by #371
Closed

no-neck-pain exits neovim when closing a tab page with no-neck-pane enabled #370

lorentzforces opened this issue Jun 22, 2024 · 2 comments · Fixed by #371
Assignees
Labels
bug Something isn't working in progress When an issue is being working on

Comments

@lorentzforces
Copy link

Description

If one opens another tab page, enables no-neck-pane on that tab page, and then closes the window in that tab (via :q for example), neovim exits.

Steps to reproduce

  1. Start neovim with no-neck-pain.nvim loaded
  2. Open another tab
  3. Enable no-neck-pain in that tab
  4. Close the buffer in this tab
  5. Neovim quits entirely (with exit code 0)

Expected behavior

I would expect the current tab page to close, given that the only "non-no-neck-pain" window in the tab page has closed. The entire editor quitting is unexpected.

Environment

  • Neovim version: 0.10.0
  • no-neck-pain.nvim version: tested with latest
  • Plugin clash: no other plugins loaded

I have created a repo that will create a docker image with a minimal reproduction setup. Reference as needed for a built setup, or just for a concrete series of actions which result in the observed behavior.

Happy to perform additional troubleshooting on request.

While I'm here, also just want to share that I love this plugin. I frequently have single buffers open (and am a stickler for limiting line lengths in my code), and really like being able to center what I'm looking at.

@shortcuts
Copy link
Owner

Hey @lorentzforces, thanks for using the plugin and the super detailed reproduction!!

I can confirm I'm able to reproduce the issue, I'll try to find a solution!

@shortcuts shortcuts self-assigned this Jun 24, 2024
@shortcuts shortcuts added bug Something isn't working in progress When an issue is being working on labels Jun 24, 2024
shortcuts added a commit that referenced this issue Jun 26, 2024
## 📃 Summary

close #370

we do not account for remaining tabs when determining if we should quit
nvim or just disable the plugin
@lorentzforces
Copy link
Author

Amazing, thank you for the fix, and thanks again for a great plugin.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working in progress When an issue is being working on
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants