Closed
Description
Self-Diagnosis
- I have searched the issues for an answer to my question.
- I have reviewed the NERDTree documentation.
:h NERDTree
- I have reviewed the Wiki.
- I have searched the web for an answer to my question.
Environment (for bug reports)
- Operating System: Ubuntu 18.04 (LTS)
- Vim/Neovim version: VIM - Vi IMproved 8.0
- NERDTree version, found on 1st line in NERDTree quickhelp
?
: 6.3.0 - vimrc settings
- NERDTree variables
let g:NERDTreeShowHidden=1 let g:NERDTreeAutoDeleteBuffer=1
- Other NERDTree-dependent Plugins
- jistr/vim-nerdtree-tabs
- ryanoasis/vim-devicons
- tiagofumo/vim-nerdtree-syntax-highlight
- Xuyuanp/nerdtree-git-plugin
- [] Others (specify):
- I've verified the issue occurs with only NERDTree installed.
Steps to Reproduce the Issue
echo "## Hello" > /tmp/a.md
vim /tmp/a.md
- Toggle NERDTree open and select the file
mm
to move the file- Change the file name from
a.md
tob.md
Current Result (Include screenshots where appropriate.)
The buffer correctly switches to b.md
but the file type has been removed which in turn removes the syntax highlighting.
Now we need to run either set ft=markdown
or :e
manually and things work again.
Expected Result
The buffer would have b.md
open with the file type set to Markdown which in turn has correct syntax highlighting without having to manually do anything extra.