NERD_Tree sets a custom filetype when it creates its window. You can hook into that with an :autocmd
that removes the buffer-local mapping for ?
. Unfortunately, it apparently sets the filetype before setting up it's mappings, but something like this should work (except for directly after opening the tree for the first time):
Put the following into your ~/.vimrc
:
:autocmd FileType nerdtree autocmd WinEnter,CursorHold <buffer> silent! nunmap <buffer> ?
Edit: I've just submitted a patch to the author that would enable this shorter and better hook (though the config variable would still be preferred for this particular use case):
:autocmd FileType nerdtree silent! nunmap <buffer> ?