sillybun / vim-repl

Best REPL environment for Vim
GNU General Public License v2.0
446 stars 39 forks source link

VIM exits during Buffer navigation after REPLHide in Win10 #126

Open echaya opened 3 years ago

echaya commented 3 years ago

Describe the bug

VIM will exit itself after I use :REPLHide and navigate to the hidden buffer. Please see the gif

Screenshots

buffer navigation

Desktop (please complete the following information):

Additional context

let me know in case any further info is needed. thanks!

lrittel commented 2 years ago

Vim quitting when the repl is the only remaining window after closing all other windows is intended behavior. This is triggered by the BufEnter event which also fires when you switch to another buffer in the same window: https://github.com/sillybun/vim-repl/blob/3ba3baa5924b8dd41c482e68da0dd3bb35e13acd/autoload/repl.vim#L281 That may be the source of the observed behavior. Using the WinEnter or even better the WinClose event instead should fix this. But I don't know if that causes other bugs or breaks intended behavior … @sillybun ? :D