0

Here is what is happening:

  1. I open one file, either with o in NERDTree or with :edit file_a.
  2. I open another file, again with o in NERDTree or with :edit file_b, and the file opens at the same window as file_a (no problem with that).
  3. Then, I do :bw or :bd and Vim exits.

I found that this is NERDTree. If I run vim by

vim -u NONE -U NONE -N

then when I open two files on the same window and I use :bd or :bw, Vim is not exiting and only the buffer that I choose to delete or wipe closes.

But, when I install NERDTree, then when I have again two buffers on the same window and I close one (with either :bd or :bw) the window closes and only NERDTree window stays open.

This is with plain NERDTree. No extra settings.

My .vimrc file is:

set nocompatible
filetype plugin indent on
call plug#begin('~/.vim/plugged')
Plug 'scrooloose/nerdtree'
call plug#end()
10
  • 2
    Can you share with us a minimal vimrc which allows you to reproduce this issue? (and have a read here) – statox Jul 3 '20 at 14:56
  • @statox thnx! I will upload. – Xxxo Jul 3 '20 at 14:58
  • 1
    Then it seems that it is my vimrc. I will do the debugging and update my questions. – Xxxo Jul 3 '20 at 15:00
  • 1
    I understand, I pointed you to the issue tracker because it's more likely that the maintainers of the plugin know about the issue and how to solve it rather than people on this site who may or may not use the plugin and may or may not experience the issue. And I recommended getting rid of it because I have seen dozens of questions on this site caused by NERDTree's bugs and I have also used it and been frustrated numerous time before deciding to stop using it. Of course you are free to continue to use it but it's just a friendly advice as someone who has a bit of experience with this plugin :) – statox Jul 3 '20 at 15:27
  • 1
    Thnx! The truth is that I will probably move away from NERDTree... but I want to solve this bug :D But you gave me good information, thank you very much! – Xxxo Jul 3 '20 at 15:32

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.