Ⅰ. 插件描述
Vim plugin for synchronizing current open file with NERDtreeⅡ. 基本信息
|
Ⅲ. 安装方法
使用Vundle管理器安装
在你的.vimrc下添加:Plugin 'unkiwii/vim-nerdtree-sync'
… 然后在Vim中运行以下命令:
:source %
:PluginInstall
对于Vundle版本 < 0.10.2,请用上面的Bundle替换Plugin。
使用NeoBundle管理器安装
在你的.vimrc下添加:NeoBundle 'unkiwii/vim-nerdtree-sync'
… 然后在Vim中运行以下命令:
:source %
:NeoBundleInstall
使用VimPlug管理器安装
在你的.vimrc下添加:Plug 'unkiwii/vim-nerdtree-sync'
… 然后在Vim中运行以下命令:
:source %
:PlugInstall
使用Pathogen管理器安装
在终端中运行以下命令:cd ~/.vim/bundle
git clone https://github.com/unkiwii/vim-nerdtree-sync
Ⅳ. 文档说明
# vim-nerdtree-sync
A plugin that show the current file on NERDtree

Install
- Pathogen
git clone https://github.com/unkiwii/vim-nerdtree-sync.git ~/.vim/bundle/vim-nerdtree-sync - vim-plug
Plug 'unkiwii/vim-nerdtree-sync' - NeoBundle
NeoBundle 'unkiwii/vim-nerdtree-sync' - Vundle
Plugin 'unkiwii/vim-nerdtree-sync'
How it works
After open a file, if NERDTree is open, it will show that file in NERDTree window. If you have cursorline enabled it will also highlight the file.
If you don't have cursorline setted or don't want to set it you can configure the plugin to highlight the file:
let g:nerdtree_sync_cursorline = 1Or configure NERDTree to always show the cursorline:
let g:NERDTreeHighlightCursorline = 1That will run setlocal cursorline in the NERDTree window
Credits
License
DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE
Version 2, December 2004
Copyright (C) 2017 Lucas Gabriel Sanchez <unkiwii@gmail.com>
Everyone is permitted to copy and distribute verbatim or modified
copies of this license document, and changing it is allowed as long
as the name is changed.
DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE
TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION
0. You just DO WHAT THE FUCK YOU WANT TO.