From 026bfaf35ef7ee11fd77c805500d5c746c71440d Mon Sep 17 00:00:00 2001 From: "Phil Runninger (mac)" Date: Wed, 15 Aug 2018 13:22:06 +0000 Subject: [PATCH] Do a case sensitive comparison of new/existing buffers. When NERTDtree opens a file, it compares this new file to all open buffers to see if it's already open. If the user has 'ignorecase' turned on then the comparison of "file" and "File" says they're the same, and NERDTree won't reopen the file. This commit forces a case sensitive comparison by using the ==# operator. --- lib/nerdtree/path.vim | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/nerdtree/path.vim b/lib/nerdtree/path.vim index 0aa592e2..912c5372 100644 --- a/lib/nerdtree/path.vim +++ b/lib/nerdtree/path.vim @@ -817,7 +817,7 @@ function! s:Path.tabnr() let str = self.str() for t in range(tabpagenr('$')) for b in tabpagebuflist(t+1) - if str == expand('#' . b . ':p') + if str ==# expand('#' . b . ':p') return t+1 endif endfor