vim-session icon indicating copy to clipboard operation
vim-session copied to clipboard

Session.vim with NERDTree: One tab disappears on OpenSession

Open eric-hu opened this issue 11 years ago • 6 comments

I normally browse with NERDTree open in the current project folder. NERDTree sits in its own tab (at tab position 0) and I open each project file in a new tab.

Using either :SaveSession or autosave, I can reload my last session, but one tab is missing--the one next to the NERDTree tab.

If I keep a file open in the same tab as NERDTree, this doesn't seem to happen.

eric-hu avatar Oct 22 '12 19:10 eric-hu

Not completely sure if it's the same issue but I'm also running into issues while opening a saved session w/ NERDTree open in every tab. In my setup, I have NERDTree open in the left split in EVERY tab (TextMate-style Rails development). When I reopen the session (which had 2 tabs open with a file + NERDTree in each tab), the first tab looks OK but the second tab opens with 4 splits - one with NERDTree, one contains an empty file (titled "No Name") and the last two splits contain the file that should've been opened instead of "No Name" in the second split alone.

baseliners avatar Jun 04 '13 23:06 baseliners

The issue reported by @eric-hu should be fixed in version 2.4.1 (just released).

xolox avatar Jun 22 '13 03:06 xolox

@baseliners After fixing the issue reported by @eric-hu I can not reproduce the issue you reported. Can you try version 2.4.1 to see whether it resolves the problem for you?

xolox avatar Jun 22 '13 03:06 xolox

Thanks for the update @xolox ! Confirmed that this fixes my original issue (after adding "Bundle 'xolox/vim-misc'" to my .vimrc to setup Vundler).

eric-hu avatar Jun 24 '13 00:06 eric-hu

@xolox Thanks for letting me know. I tried out the latest version from master (2.4.4) commit d5c3b6af658eea93ddfeba5f58f3975c223e7f82 and the problem still exists - same symptoms as previously reported with the second tab having 4 splits instead of 2. Let me know if you want me to test on 2.4.1 instead of the latest.

baseliners avatar Jun 30 '13 21:06 baseliners

Just a note to anyone else running into this - if you open gvim from the terminal and specify the session file using -S, the session is restored correctly without the additional splits. i.e. gvim -S <path_to_session_file.vim>

baseliners avatar Aug 18 '13 00:08 baseliners