vim-nerdtree-tabs icon indicating copy to clipboard operation
vim-nerdtree-tabs copied to clipboard

Conflict with user's config for TabEnter

Open hmgle opened this issue 9 years ago • 0 comments
trafficstars

I am using this vim config to jump to the left tab after closing current tab:

let s:prevtabnum=tabpagenr('$')
let s:prevtabid=tabpagenr()
augroup TabClosed
    autocmd! TabEnter * :if tabpagenr('$')<s:prevtabnum && tabpagenr()>1 && s:prevtabid != tabpagenr('$')+1
                \       |   tabprevious
                \       |endif
                \       |let s:prevtabnum=tabpagenr('$')
            \   |let s:prevtabid=tabpagenr()
augroup END

It work when NERDTree is not open. But if NERDTree is open, it will jump to the right tab after closing tab, and the gT cmd will skip the previous tab page go to the tab from the left side calculated second.

hmgle avatar Mar 17 '16 14:03 hmgle