Compare commits

..

37 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
Martin Grenfell
00ab690758 bugfix for doing :qa when a nerd tree is open in another tab 2008-10-28 21:03:39 +13:00
Martin Grenfell
d4b4d69469 when opening a file (with o), dont split unless there is no choice 2008-10-27 23:21:39 +13:00
Martin Grenfell
283559bd97 fix a bug where directories starting with + couldnt be opened 2008-10-19 23:06:32 +13:00
Martin Grenfell
38442b06d4 refactor code to find tree indent level 2008-10-19 23:06:09 +13:00
Martin Grenfell
ae0d744357 fix a backwards compatibility bug with maps
Do an unlet <old key> when over riding a method on a prototype object.
Some older versions of vim spaz out otherwise.

Note: i was using these unlets up until a few versions ago when the were
refactored out
2008-10-16 22:55:44 +13:00
Martin Grenfell
094074d8c6 correct version in changelog 2008-10-16 22:34:48 +13:00
Martin Grenfell
9b192b4be4 bump the version 2008-10-12 10:31:00 +13:00
Martin Grenfell
5fcdd03f12 refactor the help page slightly
put all the option help tags in single quotes
2008-10-01 23:17:34 +13:00
Martin Grenfell
d89dbd354a dont clobber &cpo 2008-10-01 23:17:33 +13:00
Martin Grenfell
ed273e108d minor refactor to Bookmark#toRoot() 2008-09-29 11:33:58 +13:00
Martin Grenfell
03dec4cde4 rename TreeFileNode#findOpenDirSiblingWithChildren
to TreeFileNode#findOpenDirSiblingWithVisibleChildren
2008-09-24 12:42:42 +12:00
Martin Grenfell
171c3825fa bug fix for TreeDirNode#hasVisibleChildren() 2008-09-24 12:42:15 +12:00
Martin Grenfell
be2e602efa make path.bookmarkNames private 2008-09-11 12:01:54 +12:00
Martin Grenfell
2ca4573b01 switch to version 2.14.0, update changelog 2008-09-07 12:44:13 +12:00
Martin Grenfell
cdc005f46a downcase all script level function names 2008-09-05 14:34:50 +12:00
Martin Grenfell
19d5aaa513 bugfix: openRecursively2 hadnt been renamed properly 2008-09-04 15:40:09 +12:00
Martin Grenfell
83966b7563 correct a comment 2008-09-03 18:23:08 +12:00
Martin Grenfell
b2b2bdfccd make TreeDirNode#initChildren private 2008-09-03 18:20:09 +12:00
Martin Grenfell
cf8c54689b make TreeDirNode#openRecursively2 private 2008-09-03 18:19:44 +12:00
Martin Grenfell
a8cd995624 remove 2 unused methods 2008-09-03 18:14:44 +12:00
Martin Grenfell
82a6064803 fix a comment 2008-09-03 18:12:03 +12:00
Martin Grenfell
f8b51d01b7 rename all classes - remove the leading 'o' 2008-09-03 18:03:56 +12:00
Martin Grenfell
3cbb73a63c remove 2 unused function2 2008-09-03 17:57:33 +12:00
Martin Grenfell
d24a421efd cosmetic fix 2008-09-03 17:45:22 +12:00
Martin Grenfell
6cf4e9a763 move some bookmark logic into the model
move the bookmark validation logic into the model, as well as the
bookmark to root code
2008-09-03 17:40:33 +12:00
Martin Grenfell
2e26da9666 minor cosmetic change 2008-09-03 17:40:26 +12:00
Martin Grenfell
e102abe98f move a method into the TreeDirNode model 2008-09-03 16:32:14 +12:00
Martin Grenfell
4c1362aff8 rename all class instance methods to start with lower case 2008-09-03 15:58:19 +12:00
Martin Grenfell
1a4cf45f03 remove some unneeded 'unlet' calls 2008-09-03 15:06:15 +12:00
Martin Grenfell
374df70218 remove some unneeded syntax 2008-09-03 15:05:50 +12:00
Martin Grenfell
a57b867ee6 correct the comments above s:GetSelectedBookmark() 2008-08-31 20:58:08 +12:00
Martin Grenfell
927aebfa8b display bookmarks without the surrounding [ ] 2008-08-31 20:57:37 +12:00
Martin Grenfell
4f0a39159a fix some bugs with bookmarks
if #delete() was called on a bookmark that wasnt cached, the wrong error
was being "catch"ed
2008-08-31 20:56:13 +12:00
Martin Grenfell
76d2ecbb17 add keymap to delete bookmarks 2008-08-31 20:55:24 +12:00
Martin Grenfell
73322e88d2 fix a bug with the <c-w>o mapping
now we dont assume the cursor is in the nerd tree window when calling
s:SaveScreenState()
2008-08-03 16:46:48 +12:00
2 changed files with 1183 additions and 1131 deletions

View File

@@ -122,7 +122,7 @@ For example, you could use bookmarks to tag all of your project directories.
2.2.1. The Bookmark Table *NERDTreeBookmarkTable*
If the bookmark table is active (see |NERDTree-B| and
|NERDTreeShowBookmarks|), it will be rendered above the tree. You can double
|'NERDTreeShowBookmarks'|), it will be rendered above the tree. You can double
click bookmarks or use the |NERDTree-o| mapping to activate them. See also,
|NERDTree-t| and |NERDTree-T|
@@ -160,7 +160,7 @@ Note that the following commands are only available in the NERD tree buffer.
Remove all bookmarks.
:ReadBookmarks
Re-read the bookmarks in the |NERDTreeBookmarksFile|.
Re-read the bookmarks in the |'NERDTreeBookmarksFile'|.
See also |:NERDTree| and |:NERDTreeFromBookmark|.
@@ -171,7 +171,7 @@ If invalid bookmarks are detected, the script will issue an error message and
the invalid bookmarks will become unavailable for use.
These bookmarks will still be stored in the bookmarks file (see
|NERDTreeBookmarksFile|), down the bottom. There will always be a blank line
|'NERDTreeBookmarksFile'|), down the bottom. There will always be a blank line
after the valid bookmarks but before the invalid ones.
Each line in the bookmarks file represents one bookmark. The proper format is:
@@ -202,6 +202,8 @@ double-click.......same as the |NERDTree-o| map.
middle-click.......same as |NERDTree-tab| for files, same as
|NERDTree-e| for dirs.
D.......Delete the current bookmark .............................|NERDTree-D|
P.......Jump to the root node....................................|NERDTree-P|
p.......Jump to current nodes parent.............................|NERDTree-p|
K.......Jump up inside directories at the current tree depth.....|NERDTree-K|
@@ -312,8 +314,8 @@ Applies to: directories.
Recursively opens the selelected directory.
All files and directories are cached, but if a directory would not be
displayed due to file filters (see |NERDTreeIgnore| |NERDTree-f|) or the
hidden file filter (see |NERDTreeShowHidden|) then its contents are not
displayed due to file filters (see |'NERDTreeIgnore'| |NERDTree-f|) or the
hidden file filter (see |'NERDTreeShowHidden'|) then its contents are not
cached. This is handy, especially if you have .svn directories.
------------------------------------------------------------------------------
@@ -342,6 +344,14 @@ Applies to: files and directories.
Opens a netrw on the selected directory, or the selected file's directory.
------------------------------------------------------------------------------
*NERDTree-D*
Default key: D
Map option: NERDTreeMapDeleteBookmark
Applies to: lines in the bookmarks table
Deletes the currently selected bookmark.
------------------------------------------------------------------------------
*NERDTree-P*
Default key: P
@@ -467,7 +477,7 @@ Default key: f
Map option: NERDTreeMapToggleFilters
Applies to: no restrictions.
Toggles whether file filters are used. See |NERDTreeIgnore| for details.
Toggles whether file filters are used. See |'NERDTreeIgnore'| for details.
------------------------------------------------------------------------------
*NERDTree-F*
@@ -551,53 +561,53 @@ then id be grateful if you'd email me.
The script provides the following options that can customise the behaviour the
NERD tree. These options should be set in your vimrc.
|loaded_nerd_tree| Turns off the script.
|'loaded_nerd_tree'| Turns off the script.
|NERDChristmasTree| Tells the NERD tree to make itself colourful
|'NERDChristmasTree'| Tells the NERD tree to make itself colourful
and pretty.
|NERDTreeAutoCenter| Controls whether the NERD tree window centers
|'NERDTreeAutoCenter'| Controls whether the NERD tree window centers
when the cursor moves within a specified
distance to the top/bottom of the window.
|NERDTreeAutoCenterThreshold| Controls the sensitivity of autocentering.
|'NERDTreeAutoCenterThreshold'| Controls the sensitivity of autocentering.
|NERDTreeCaseSensitiveSort| Tells the NERD tree whether to be case
|'NERDTreeCaseSensitiveSort'| Tells the NERD tree whether to be case
sensitive or not when sorting nodes.
|NERDTreeChDirMode| Tells the NERD tree if/when it should change
|'NERDTreeChDirMode'| Tells the NERD tree if/when it should change
vim's current working directory.
|NERDTreeHighlightCursorline| Tell the NERD tree whether to highlight the
|'NERDTreeHighlightCursorline'| Tell the NERD tree whether to highlight the
current cursor line.
|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.
|NERDTreeMouseMode| Tells the NERD tree how to handle mouse
|'NERDTreeMouseMode'| Tells the NERD tree how to handle mouse
clicks.
|NERDTreeQuitOnOpen| Closes the tree window after opening a file.
|'NERDTreeQuitOnOpen'| Closes the tree window after opening a file.
|NERDTreeShowBookmarks| Tells the NERD tree whether to display the
|'NERDTreeShowBookmarks'| Tells the NERD tree whether to display the
bookmarks table on startup.
|NERDTreeShowFiles| Tells the NERD tree whether to display files
|'NERDTreeShowFiles'| Tells the NERD tree whether to display files
in the tree on startup.
|NERDTreeShowHidden| Tells the NERD tree whether to display hidden
|'NERDTreeShowHidden'| Tells the NERD tree whether to display hidden
files on startup.
|NERDTreeShowLineNumbers| Tells the NERD tree whether to display line
|'NERDTreeShowLineNumbers'| Tells the NERD tree whether to display line
numbers in the tree window.
|NERDTreeSortOrder| Tell the NERD tree how to sort the nodes in
|'NERDTreeSortOrder'| Tell the NERD tree how to sort the nodes in
the tree.
|NERDTreeWinPos| Tells the script where to put the NERD tree
|'NERDTreeWinPos'| Tells the script where to put the NERD tree
window.
|NERDTreeWinSize| Sets the window size when the NERD tree is
|'NERDTreeWinSize'| Sets the window size when the NERD tree is
opened.
------------------------------------------------------------------------------
@@ -606,13 +616,13 @@ NERD tree. These options should be set in your vimrc.
To enable any of the below options you should put the given line in your
~/.vimrc
*loaded_nerd_tree*
*'loaded_nerd_tree'*
If this plugin is making you feel homicidal, it may be a good idea to turn it
off with this line in your vimrc: >
let loaded_nerd_tree=1
<
------------------------------------------------------------------------------
*NERDChristmasTree*
*'NERDChristmasTree'*
Values: 0 or 1.
Default: 1.
@@ -622,12 +632,12 @@ added to the nerd tree to make it more colourful.
Set it to 0 for a more vanilla looking tree.
------------------------------------------------------------------------------
*NERDTreeAutoCenter*
*'NERDTreeAutoCenter'*
Values: 0 or 1.
Default: 1
If set to 1, the NERD tree window will center around the cursor if it moves to
within |NERDTreeAutoCenterThreshold| lines of the top/bottom of the window.
within |'NERDTreeAutoCenterThreshold'| lines of the top/bottom of the window.
This is ONLY done in response to tree navigation mappings,
i.e. |NERDTree-J| |NERDTree-K| |NERDTree-C-J| |NERDTree-c-K| |NERDTree-p|
@@ -636,15 +646,15 @@ i.e. |NERDTree-J| |NERDTree-K| |NERDTree-C-J| |NERDTree-c-K| |NERDTree-p|
The centering is done with a |zz| operation.
------------------------------------------------------------------------------
*NERDTreeAutoCenterThreshold*
*'NERDTreeAutoCenterThreshold'*
Values: Any natural number.
Default: 3
This option controls the "sensitivity" of the NERD tree auto centering. See
|NERDTreeAutoCenter| for details.
|'NERDTreeAutoCenter'| for details.
------------------------------------------------------------------------------
*NERDTreeCaseSensitiveSort*
*'NERDTreeCaseSensitiveSort'*
Values: 0 or 1.
Default: 0.
@@ -665,7 +675,7 @@ account. The above nodes would then be sorted like this: >
boner.c
<
------------------------------------------------------------------------------
*NERDTreeChDirMode*
*'NERDTreeChDirMode'*
Values: 0, 1 or 2.
Default: 0.
@@ -688,7 +698,7 @@ is /home/marty/foobar and you make the node for /home/marty/foobar/baz the new
root then the CWD will become /home/marty/foobar/baz.
------------------------------------------------------------------------------
*NERDTreeHighlightCursorline*
*'NERDTreeHighlightCursorline'*
Values: 0 or 1.
Default: 1.
@@ -696,13 +706,14 @@ If set to 1, the current cursor line in the NERD tree buffer will be
highlighted. This is done using the |cursorline| option.
------------------------------------------------------------------------------
*NERDTreeIgnore*
*'NERDTreeIgnore'*
Values: a list of regular expressions.
Default: ['\~$'].
This option is used to specify which files the NERD tree should ignore. It
must be a list of regular expressions. When the NERD tree is rendered, any
files/dirs that match any of the regex's in NERDTreeIgnore wont be displayed.
files/dirs that match any of the regex's in 'NERDTreeIgnore' wont be
displayed.
For example if you put the following line in your vimrc: >
let NERDTreeIgnore=['\.vim$', '\~$']
@@ -718,14 +729,14 @@ The file filters can be turned on and off dynamically with the |NERDTree-f|
mapping.
------------------------------------------------------------------------------
*NERDTreeBookmarksFile*
*'NERDTreeBookmarksFile'*
Values: a path
Default: $HOME/.NERDTreeBookmarks
This is where bookmarks are saved. See |NERDTreeBookmarkCommands|.
------------------------------------------------------------------------------
*NERDTreeMouseMode*
*'NERDTreeMouseMode'*
Values: 1, 2 or 3.
Default: 1.
@@ -743,7 +754,7 @@ then (to single click activate it) you must click somewhere in
'application.rb'.
------------------------------------------------------------------------------
*NERDTreeQuitOnOpen*
*'NERDTreeQuitOnOpen'*
Values: 0 or 1.
Default: 0
@@ -752,16 +763,17 @@ If set to 1, the NERD tree window will close after opening a file with the
|NERDTree-o| or |NERDTree-tab| mappings.
------------------------------------------------------------------------------
*NERDTreeShowBookmarks*
*'NERDTreeShowBookmarks'*
Values: 0 or 1.
Default: 0.
If this option is set to 1 then the bookmarks table will be displayed.
This option can be toggled dynamically, per tree, with the |NERDTree-B| mapping.
This option can be toggled dynamically, per tree, with the |NERDTree-B|
mapping.
------------------------------------------------------------------------------
*NERDTreeShowFiles*
*'NERDTreeShowFiles'*
Values: 0 or 1.
Default: 1.
@@ -773,7 +785,7 @@ mapping and is useful for drastically shrinking the tree when you are
navigating to a different part of the tree.
------------------------------------------------------------------------------
*NERDTreeShowHidden*
*'NERDTreeShowHidden'*
Values: 0 or 1.
Default: 0.
@@ -785,7 +797,7 @@ of the follow lines to set this option: >
<
------------------------------------------------------------------------------
*NERDTreeShowLineNumbers*
*'NERDTreeShowLineNumbers'*
Values: 0 or 1.
Default: 0.
@@ -796,7 +808,7 @@ window. Use one of the follow lines to set this option: >
<
------------------------------------------------------------------------------
*NERDTreeSortOrder*
*'NERDTreeSortOrder'*
Values: a list of regular expressions.
Default: ['\/$', '*', '\.swp$', '\.bak$', '\~$']
@@ -811,8 +823,8 @@ all .h files. All files containing the string 'foobar' will be placed at the
end. The star is a special flag: it tells the script that every node that
doesnt match any of the other regexps should be placed here.
If no star is present in NERDTreeSortOrder then one is automatically appended
to the array.
If no star is present in 'NERDTreeSortOrder' then one is automatically
appended to the array.
The regex '\/$' should be used to match directory nodes.
@@ -829,7 +841,7 @@ Other examples: >
backup files will appear last with everything else preceding them.
------------------------------------------------------------------------------
*NERDTreeWinPos*
*'NERDTreeWinPos'*
Values: "left", "right", "top" or "bottom"
Default: "left".
@@ -844,7 +856,7 @@ plugins simultaneously. For example, you could have the taglist plugin on the
left of the window and the NERD tree on the right.
------------------------------------------------------------------------------
*NERDTreeWinSize*
*'NERDTreeWinSize'*
Values: a positive integer.
Default: 31.
@@ -889,6 +901,27 @@ fridge for later ;)
==============================================================================
7. Changelog *NERDTreeChangelog*
2.14.2
- 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
with other explorer plugins. Thanks to Ryan Penn, Simon Peter Nicholls
and Michael
- fix a bug where directories starting with a '+' char could not be opened.
Thanks to Tomasz Chomiuk.
- fix a bug where closing vim with :qa with a tree open in another tab
would break, thanks to Denis Pokataev.
- compatibility bugfix for older versions of vim, thanks to knekk for
helping me track it down and to Sean Chou.
2.14.1
- dont clobber &cpo. Thanks to godlygeek for the bug report.
2.14.0
- fix a bug where the <c-w>o mapping would cause the tree window to be
incorrectly sized when reopened.
- add keymapping to delete bookmarks from the bookmarks table, see
:help NERDTree-D
- lots of refactoring
2.13.0
- make NERDTreeChDir option default to 0 (i.e. never change vims current
working dir by default)
@@ -922,8 +955,8 @@ fridge for later ;)
- applied a patch from Matan Nassau to add the NERDTreeQuitOnOpen option
which closes the tree window after opening a file. See :help
NERDTreeQuitOnOpen.
- optimised the nerd tree rendering. Now it takes just over 1/3 of the time
it previously took to render.
- optimised the nerd tree rendering. Now it takes just over 1/3 of the
time it previously took to render.
- now the tree filter mappings toggle the filters "per tree" rather than
globally. The global filter variables are used to set the initial filter
settings for each new NERD tree.
@@ -999,9 +1032,9 @@ fridge for later ;)
and you use <c-j/k> the cursor will jump to its PARENTS next/previous
sibling. Go :help NERDTree-c-j and :help NERDTree-c-k for info.
- Extended the behaviour of the J/K mappings. Now if the cursor is on the
last child of a node and you push J/K it will jump down to the last child
of the next/prev of its parents siblings that is open and has children.
Go :help NERDTree-J and :help NERDTree-K for info.
last child of a node and you push J/K it will jump down to the last
child of the next/prev of its parents siblings that is open and has
children. Go :help NERDTree-J and :help NERDTree-K for info.
- The goal of these changes is to make tree navigation faster.
- Reorganised the help page a bit.
- Removed the E mapping.
@@ -1041,8 +1074,8 @@ fridge for later ;)
- Tree navigation changes:
- Added J and K mappings to jump to last/first child of the current dir.
Options to customise these mappings have also been added.
- Remapped the jump to next/prev sibling commands to be <C-j> and <C-k> by
default.
- Remapped the jump to next/prev sibling commands to be <C-j> and <C-k>
by default.
These changes should hopefully make tree navigation mappings easier to
remember and use as the j and k keys are simply reused 3 times (twice
with modifier keys).
@@ -1204,6 +1237,23 @@ NERDTreeQuitOnOpen was set.
Thanks to Charlton Wang for reporting bugs with the 'o' mapping and with
handling named pipes.
Chur to godlygeek for reporting a bug where &cpo was getting clobbered.
Cheers to knekk for helping me track down a bug when overwriting dictionary
keys that only occurred in some versions of vim.
Thanks also to Sean Chou for the bug report about the above bug.
Thanks to Ryan Penn, Simon Peter Nicholls and Michael for pointing out an issue
where the script was splitting constantly when using the 'o' mapping while
other explorers were open.
Thanks to Tomasz Chomiuk for the bug report about the script failing when dir
names began with a +.
Thanks to Denis Pokataev for the bug report about the script failing when
closing vim with :qa with a tree open in another tab.
==============================================================================
9. License *NERDTreeLicense*

File diff suppressed because it is too large Load Diff