Compare commits

..

2 Commits

Author SHA1 Message Date
Martin Grenfell
090791407e switch to version 2.14.2 2008-10-29 20:14:08 +13:00
Martin Grenfell
cea02c6d98 update changelog and credits 2008-10-29 20:04:49 +13:00
2 changed files with 247 additions and 489 deletions

View File

@@ -31,7 +31,7 @@ CONTENTS *NERDTree-contents*
3.Options.................................|NERDTreeOptions| 3.Options.................................|NERDTreeOptions|
3.1 Option summary....................|NERDTreeOptionSummary| 3.1 Option summary....................|NERDTreeOptionSummary|
3.2 Option details....................|NERDTreeOptionDetails| 3.2 Option details....................|NERDTreeOptionDetails|
4.Hacking the NERD tree...................|NERDTreeHacking| 4.Public functions........................|NERDTreePublicFunctions|
5.TODO list...............................|NERDTreeTodo| 5.TODO list...............................|NERDTreeTodo|
6.The Author..............................|NERDTreeAuthor| 6.The Author..............................|NERDTreeAuthor|
7.Changelog...............................|NERDTreeChangelog| 7.Changelog...............................|NERDTreeChangelog|
@@ -65,7 +65,7 @@ The following features and functionality are provided by the NERD tree:
* ... * ...
* Directories and files can be bookmarked. * Directories and files can be bookmarked.
* Most NERD tree navigation can also be done with the mouse * Most NERD tree navigation can also be done with the mouse
* Filtering of tree content (can be toggled at runtime) * Dynamic customisation of tree content
* custom file filters to prevent e.g. vim backup files being displayed * custom file filters to prevent e.g. vim backup files being displayed
* optional displaying of hidden files (. files) * optional displaying of hidden files (. files)
* files can be "turned off" so that only directories are displayed * files can be "turned off" so that only directories are displayed
@@ -81,13 +81,9 @@ The following features and functionality are provided by the NERD tree:
session, the directory nodes will be opened/closed as you left them session, the directory nodes will be opened/closed as you left them
* The script remembers the cursor position and window position in the NERD * The script remembers the cursor position and window position in the NERD
tree so you can toggle it off (or just close the tree window) and then tree so you can toggle it off (or just close the tree window) and then
reopen it (with NERDTreeToggle) the NERD tree window will appear exactly reopen it (with NERDTreeToggle) the NERD tree window will appear EXACTLY
as you left it as you left it
* You can have a separate NERD tree for each tab, share trees across tabs, * You can have a separate NERD tree for each tab
or a mix of both.
* By default the script overrides the default file browser (netw), so if
you :edit a directory a (slighly modified) NERD tree will appear in the
current window
============================================================================== ==============================================================================
2. Functionality provided *NERDTreeFunctionality* 2. Functionality provided *NERDTreeFunctionality*
@@ -113,15 +109,7 @@ The following features and functionality are provided by the NERD tree:
again. If no NERD tree exists for this tab then this command acts the again. If no NERD tree exists for this tab then this command acts the
same as the |:NERDTree| command. same as the |:NERDTree| command.
:NERDTreeMirror *:NERDTreeMirror* :NERDTreeClose
Shares an existing NERD tree, from another tab, in the current tab.
Changes made to one tree are reflected in both as they are actually the
same buffer.
If only one other NERD tree exists, that tree is automatically mirrored. If
more than one exists, the script will ask which tree to mirror.
:NERDTreeClose *:NERDTreeClose*
Close the NERD tree in this tab. Close the NERD tree in this tab.
------------------------------------------------------------------------------ ------------------------------------------------------------------------------
@@ -202,16 +190,16 @@ o.......Open files, directories and bookmarks....................|NERDTree-o|
go......Open selected file, but leave cursor in the NERDTree.....|NERDTree-go| go......Open selected file, but leave cursor in the NERDTree.....|NERDTree-go|
t.......Open selected node/bookmark in a new tab.................|NERDTree-t| t.......Open selected node/bookmark in a new tab.................|NERDTree-t|
T.......Same as 't' but keep the focus on the current tab........|NERDTree-T| T.......Same as 't' but keep the focus on the current tab........|NERDTree-T|
i.......Open selected file in a split window.....................|NERDTree-i| <tab>...Open selected file in a split window.....................|NERDTree-tab|
gi......Same as i, but leave the cursor on the NERDTree..........|NERDTree-i| g<tab>..Same as <tab>, but leave the cursor on the NERDTree......|NERDTree-gtab|
!.......Execute the current file.................................|NERDTree-!| !.......Execute the current file.................................|NERDTree-!|
O.......Recursively open the selected directory..................|NERDTree-O| O.......Recursively open the selected directory..................|NERDTree-O|
x.......Close the current nodes parent...........................|NERDTree-x| x.......Close the current nodes parent...........................|NERDTree-x|
X.......Recursively close all children of the current node.......|NERDTree-X| X.......Recursively close all children of the current node.......|NERDTree-X|
e.......Edit the current dif.....................................|NERDTree-e| e.......Open a netrw for the current dir.........................|NERDTree-e|
double-click.......same as the |NERDTree-o| map. double-click.......same as the |NERDTree-o| map.
middle-click.......same as |NERDTree-i| for files, same as middle-click.......same as |NERDTree-tab| for files, same as
|NERDTree-e| for dirs. |NERDTree-e| for dirs.
D.......Delete the current bookmark .............................|NERDTree-D| D.......Delete the current bookmark .............................|NERDTree-D|
@@ -231,7 +219,7 @@ R.......Recursively refresh the current root.....................|NERDTree-R|
m.......Display the filesystem menu..............................|NERDTree-m| m.......Display the filesystem menu..............................|NERDTree-m|
cd......Change the CWD to the dir of the selected node...........|NERDTree-cd| cd......Change the CWD to the dir of the selected node...........|NERDTree-cd|
I.......Toggle whether hidden files displayed....................|NERDTree-I| H.......Toggle whether hidden files displayed....................|NERDTree-H|
f.......Toggle whether the file filters are used.................|NERDTree-f| f.......Toggle whether the file filters are used.................|NERDTree-f|
F.......Toggle whether files are displayed.......................|NERDTree-F| F.......Toggle whether files are displayed.......................|NERDTree-F|
B.......Toggle whether the bookmark table is displayed...........|NERDTree-B| B.......Toggle whether the bookmark table is displayed...........|NERDTree-B|
@@ -290,8 +278,8 @@ Applies to: files and directories.
The same as |NERDTree-t| except that the focus is kept in the current tab. The same as |NERDTree-t| except that the focus is kept in the current tab.
------------------------------------------------------------------------------ ------------------------------------------------------------------------------
*NERDTree-i* *NERDTree-tab*
Default key: i Default key: <tab>
Map option: NERDTreeMapOpenSplit Map option: NERDTreeMapOpenSplit
Applies to: files. Applies to: files.
@@ -299,15 +287,15 @@ Opens the selected file in a new split window and puts the cursor in the new
window. window.
------------------------------------------------------------------------------ ------------------------------------------------------------------------------
*NERDTree-gi* *NERDTree-gtab*
Default key: gi Default key: g<tab>
Map option: None Map option: None
Applies to: files. Applies to: files.
The same as |NERDTree-i| except that the cursor is not moved. The same as |NERDTree-tab| except that the cursor is not moved.
The key combo for this mapping is always "g" + NERDTreeMapOpenSplit (see The key combo for this mapping is always "g" + NERDTreeMapOpenSplit (see
|NERDTree-i|). |NERDTree-tab|).
------------------------------------------------------------------------------ ------------------------------------------------------------------------------
*NERDTree-!* *NERDTree-!*
@@ -354,9 +342,7 @@ Default key: e
Map option: NERDTreeMapOpenExpl Map option: NERDTreeMapOpenExpl
Applies to: files and directories. Applies to: files and directories.
|:edit|s the selected directory, or the selected file's directory. This could Opens a netrw on the selected directory, or the selected file's directory.
result in a NERD tree or a netrw being opened, depending on
|'NERDTreeHijackNetrw'|.
------------------------------------------------------------------------------ ------------------------------------------------------------------------------
*NERDTree-D* *NERDTree-D*
@@ -477,12 +463,13 @@ Applies to: files and directories.
Display the filesystem menu. See |NERDTreeFilesysMenu| for details. Display the filesystem menu. See |NERDTreeFilesysMenu| for details.
------------------------------------------------------------------------------ ------------------------------------------------------------------------------
*NERDTree-I* *NERDTree-H*
Default key: I Default key: H
Map option: NERDTreeMapToggleHidden Map option: NERDTreeMapToggleHidden
Applies to: no restrictions. Applies to: no restrictions.
Toggles whether hidden files (i.e. "dot files") are displayed. Toggles whether hidden files are displayed. Hidden files are any
file/directory that starts with a "."
------------------------------------------------------------------------------ ------------------------------------------------------------------------------
*NERDTree-f* *NERDTree-f*
@@ -593,9 +580,6 @@ NERD tree. These options should be set in your vimrc.
|'NERDTreeHighlightCursorline'| Tell the NERD tree whether to highlight the |'NERDTreeHighlightCursorline'| Tell the NERD tree whether to highlight the
current cursor line. current cursor line.
|'NERDTreeHijackNetrw'| Tell the NERD tree whether to replace the netrw
autocommands for exploring local directories.
|'NERDTreeIgnore'| Tells the NERD tree which files to ignore. |'NERDTreeIgnore'| Tells the NERD tree which files to ignore.
|'NERDTreeBookmarksFile'| Where the bookmarks are stored. |'NERDTreeBookmarksFile'| Where the bookmarks are stored.
@@ -721,22 +705,6 @@ Default: 1.
If set to 1, the current cursor line in the NERD tree buffer will be If set to 1, the current cursor line in the NERD tree buffer will be
highlighted. This is done using the |cursorline| option. highlighted. This is done using the |cursorline| option.
------------------------------------------------------------------------------
*'NERDTreeHijackNetrw'*
Values: 0 or 1.
Default: 1.
If set to 1, doing a >
:edit <some directory>
<
will open up a "secondary" NERD tree instead of a netrw in the target window.
Secondary NERD trees behaves slighly different from a regular trees in the
following respects:
1. 'o' will open the selected file in the same window as the tree,
replacing it.
2. you can have as many secondary tree as you want in the same tab.
------------------------------------------------------------------------------ ------------------------------------------------------------------------------
*'NERDTreeIgnore'* *'NERDTreeIgnore'*
Values: a list of regular expressions. Values: a list of regular expressions.
@@ -792,7 +760,7 @@ Values: 0 or 1.
Default: 0 Default: 0
If set to 1, the NERD tree window will close after opening a file with the If set to 1, the NERD tree window will close after opening a file with the
|NERDTree-o| or |NERDTree-i| mappings. |NERDTree-o| or |NERDTree-tab| mappings.
------------------------------------------------------------------------------ ------------------------------------------------------------------------------
*'NERDTreeShowBookmarks'* *'NERDTreeShowBookmarks'*
@@ -822,7 +790,7 @@ Values: 0 or 1.
Default: 0. Default: 0.
This option tells vim whether to display hidden files by default. This option This option tells vim whether to display hidden files by default. This option
can be dynamically toggled, per tree, with the |NERDTree-I| mapping. Use one can be dynamically toggled, per tree, with the |NERDTree-H| mapping. Use one
of the follow lines to set this option: > of the follow lines to set this option: >
let NERDTreeShowHidden=0 let NERDTreeShowHidden=0
let NERDTreeShowHidden=1 let NERDTreeShowHidden=1
@@ -874,12 +842,15 @@ Other examples: >
------------------------------------------------------------------------------ ------------------------------------------------------------------------------
*'NERDTreeWinPos'* *'NERDTreeWinPos'*
Values: "left" or "right" Values: "left", "right", "top" or "bottom"
Default: "left". Default: "left".
This option is used to determine where NERD tree window is placed on the This option is used to determine where NERD tree window is placed on the
screen. screen.
"top" or "bottom", will cause a horizontal split to be created for the tree,
while "left" and "right" will cause a vertical split.
This option is makes it possible to use two different explorer type This option is makes it possible to use two different explorer type
plugins simultaneously. For example, you could have the taglist plugin on the plugins simultaneously. For example, you could have the taglist plugin on the
left of the window and the NERD tree on the right. left of the window and the NERD tree on the right.
@@ -892,9 +863,8 @@ Default: 31.
This option is used to change the size of the NERD tree when it is loaded. This option is used to change the size of the NERD tree when it is loaded.
============================================================================== ==============================================================================
4. Hacking the NERD tree *NERDTreeHacking* *NERDTreePublicFunctions*
5. Public functions ~
Public functions ~
The script provides 2 public functions for your hacking pleasure. Their The script provides 2 public functions for your hacking pleasure. Their
signatures are: > signatures are: >
@@ -909,26 +879,8 @@ style OO. To see the functions that each class provides you can read look at
the code. the code.
Use the node objects to manipulate the structure of the tree. Use the path Use the node objects to manipulate the structure of the tree. Use the path
objects to access the files/directories the tree nodes represent. objects to access the data the tree represents and to make changes to the
filesystem.
The NERD tree filetype ~
NERD tree buffers have a filetype of "nerdtree". You can use this to hack the
NERD tree via autocommands (on |FileType|) or via an ftplugin.
For example, putting this code in ~/.vim/ftplugin/nerdtree.vim would override
the o mapping, making it open the selected node in a new gvim instance. >
nnoremap <silent> <buffer> o :call <sid>openInNewVimInstance()<cr>
function! s:openInNewVimInstance()
let p = NERDTreeGetCurrentPath()
if p != {}
silent exec "!gvim " . p.strForOS(1) . "&"
endif
endfunction
<
This way you can add new mappings or :commands or override any existing
mapping.
============================================================================== ==============================================================================
5. TODO list *NERDTreeTodo* 5. TODO list *NERDTreeTodo*
@@ -949,24 +901,6 @@ fridge for later ;)
============================================================================== ==============================================================================
7. Changelog *NERDTreeChangelog* 7. Changelog *NERDTreeChangelog*
3.0.0
- hijack netrw so that doing an :edit <directory> will put a NERD tree in
the window rather than a netrw browser. See :help 'NERDTreeHijackNetrw'
- allow sharing of trees across tabs, see :help :NERDTreeMirror
- remove "top" and "bottom" as valid settings for NERDTreeWinPos
- change the '<tab>' mapping to 'i'
- change the 'H' mapping to 'I'
- lots of refactoring
2.14.3
Thanks to tpope for the following:
- use relative paths when doing edit commands if possible (useful if you
have %f on your statusline for example)
- allow relative paths for :NERDTree commands, eg ":NERDTree ../foo"
- fix a bug where the script used the directory of the current buffer
instead of vims cwd for the :NERDTree command
- bugfix for read only node highlighting
2.14.2 2.14.2
- when opening a file (with 'o' or double click) dont split the window - when opening a file (with 'o' or double click) dont split the window
unless we absolutely have to. This should make the script work better unless we absolutely have to. This should make the script work better
@@ -1320,8 +1254,6 @@ names began with a +.
Thanks to Denis Pokataev for the bug report about the script failing when Thanks to Denis Pokataev for the bug report about the script failing when
closing vim with :qa with a tree open in another tab. closing vim with :qa with a tree open in another tab.
Thanks to tpope for his dope bug reporting.
============================================================================== ==============================================================================
9. License *NERDTreeLicense* 9. License *NERDTreeLicense*

File diff suppressed because it is too large Load Diff