Ⅰ. 插件描述
Defines commands that will work on files inside a Visual selectionⅡ. 基本信息
|
Ⅲ. 安装方法
使用Vundle管理器安装
在你的.vimrc下添加:Plugin 'philrunninger/nerdtree-visual-selection'
… 然后在Vim中运行以下命令:
:source %
:PluginInstall
对于Vundle版本 < 0.10.2,请用上面的Bundle替换Plugin。
使用NeoBundle管理器安装
在你的.vimrc下添加:NeoBundle 'philrunninger/nerdtree-visual-selection'
… 然后在Vim中运行以下命令:
:source %
:NeoBundleInstall
使用VimPlug管理器安装
在你的.vimrc下添加:Plug 'philrunninger/nerdtree-visual-selection'
… 然后在Vim中运行以下命令:
:source %
:PlugInstall
使用Pathogen管理器安装
在终端中运行以下命令:cd ~/.vim/bundle
git clone https://github.com/philrunninger/nerdtree-visual-selection
Ⅳ. 文档说明
# nerdtree-visual-selection
This plugin requires NERDTree also to be installed. nerdtree-visual-selection defines key mappings that will work on nodes contained in a Visual selection in NERDTree.
There are two kinds of NERDTree:
- TabTree - Opened with
:NERDTree,:NERDTreeFocus,:NERDTreeFind, or:NERDTreeToggle - WindowTree - Opened with
vim .or:e ., among others.
This plugin does not work with WindowTree type trees, because the first file opened by it causes the NERDTree to close, and the other files in the selection to fail to open. So make sure you use the right commands to open NERDTree when using these mappings.
Where applicable, those keymappings match up with NERDTree settings. If not defined in the user's .vimrc, their default values are used. The mappings are as follows:
| NERDTree variable | default | Purpose |
|---|---|---|
| NERDTreeMapActivateNode | o | Open selected files. |
| NERDTreeMapOpenSplit | i | Open selected files in horizontal splits. |
| NERDTreeMapOpenVSplit | s | Open selected files in vertical splits. |
| NERDTreeMapOpenInTab | t | Open selected files in tabs. |
| n/a | dd | Delete selected files from disk. If open in Vim, they remain open. |
| n/a | m | Move the selected files to another directory. If open in Vim, the buffer still points to its old location. |
| n/a | c | Copy selected files to another directory. |