Commit Graph

215 Commits

Author SHA1 Message Date
Jason Franklin
0b65089122 Reimplement the bookmark comparison method
Sorting the list of user bookmarks requires care to ensure that Vim's
builtin sort function is called correctly. Previously, this function was
called incorrectly. This is why the sorting of bookmarks never worked.

The offending functions have been removed here and replaced with
"s:Bookmark.CompareBookmarksByName". To understand the necessity for
this change, read ":h sort()" for the requirements of the function
reference argument (esp., note that it must return -1, 0, or 1).

In addition to fixing this problem, the new comparison function will
inspect the "g:NERDTreeBookmarksSort" setting to determine whether
case-sensitivity is preferred in the sort. The documentation has been
modified to accurately reflect this adjustment. The change is also made
in such a way as not to break any existing configurations.

Fixes #361 ("My bookmarks aren't sorted").
2017-05-26 13:23:05 -04:00
cntoplolicon
dee152d08f correct NERDTreeIgnore pattern in doc 2016-12-23 17:51:36 +08:00
Phil Runninger
ac2d3b077a Merge branch 'disable-cascade' of git://github.com/juanibiapina/nerdtree into juanibiapina-disable-cascade 2016-09-08 01:02:17 -04:00
Juan Ibiapina
b2bbed41fa Add option to disable collapsing of diretory names 2016-03-05 14:20:04 -03:00
Greg Hurrell
9843fd3686 Make window creation command configurable
This commit adds a `NERDTreeCreatePrefix` setting that can be used to
prefix the `:edit` command that is used to create the NERDTree tree
window. Defaults to "silent", meaning that out of the box the window
will be created with "silent edit".

Users may wish to configure this to produce other effects. For example,
`NERDTreeCreatePrefix` can be set to "silent keepalt keepjumps" in order
to make NERDTree create its window with "silent keepalt keepjumps edit".

This can be used to create an effect analogous to the `g:netrw_altfile`
setting in netrw. An example of why you might want to do this is
described here:

    https://github.com/tpope/vim-vinegar/issues/25

I'm not using vim-vinegar myself, but I am using something like it here:

    https://github.com/wincent/wincent/blob/3efaa8fa50895/roles/dotfiles/files/.vim/plugin/mappings.vim#L60

And having `NERDTreeCreatePrefix` enables me to map "-" to show the
current file in context, and `^-6` to jump back to it.
2016-02-09 00:17:46 -08:00
Maxim Bublis
6251ab1e63 Add support for natural sorting order. 2016-01-19 00:21:13 -08:00
Martin Grenfell
677a83b2b6 remove NERDTreeDirArrows option
Use +/~ for windows - which seems to not have the arrow chars in its
default font. TBH I don't really understand this.

Inprove the UI indent matching so that it should handle any combo of
open/close symbol lengths e.g. the fancy arrows are 3 bytes each,
whereas +/~ are 1 byte each.
2015-11-25 23:29:00 +00:00
Martin Grenfell
d36b793656 dont use b:NERDTreeRoot internally, but leave the var there for compat
Use b:NERDTree.root instead. I will eventually remove  b:NERDTreeRoot
altogether - but this will break some other plugins so leave it for now.
2015-11-16 11:28:24 +00:00
Martin Grenfell
848857d18b rename "primary" and "secondary" trees to "tab" and "window" trees
This is much more accurate and descriptive.
2015-11-14 11:50:01 +00:00
Martin Grenfell
024966c7a8 move changelog out of the main doc, remove credits section
Changelog is not really relevant to the "usage" manual so extract it.

Contributors can be viewed on github.
2015-11-13 16:48:09 +00:00
Martin Grenfell
e4891632f5 update changelog 2015-11-13 16:45:11 +00:00
Den
f5fd121837 Incorrect path to event.vim 2015-07-30 16:28:11 +03:00
Martin Grenfell
dfe260d1d7 doc the path listener API 2015-05-12 20:45:15 +01:00
Martin Grenfell
5c2060149f doc NERDTreeAddPathFilter() 2015-05-06 21:20:52 +01:00
Devon Hinton
321de60366 Remove NERD_tree.txt typo
"If not" -> "If No"
2015-04-22 01:06:47 -07:00
ifsred
c4086667ef Fix doc map for NERDTreeMapChangeRoot 2014-08-06 12:33:23 +03:00
Martin Grenfell
f9a933991d allow plugins to override the default mappings 2014-07-15 19:00:17 +01:00
Martin Grenfell
b33d6daf0b remove the NERDChristmasTree option
If users want to customise the tree colours, this can be done trivially
in their vimrc. e.g.

    hi link NERDTreeFile error
2014-06-29 19:53:57 +01:00
Martin Grenfell
55a8954c48 update the doc/quickhelp for :Bookmark
Make it clearer that the argument is optional.

Closes #229
2014-06-29 12:37:29 +01:00
Martin Grenfell
1168f58987 update the NERDTreeCascadeOpenSingleChildDir doc 2014-06-27 19:29:38 +01:00
Martin Grenfell
0928b5b026 Merge pull request #251 from pendulm/master
fix typo and smart close single child directory
2014-06-27 19:25:48 +01:00
Martin Grenfell
8189597c0b Merge pull request #266 from staeff/patch-1
Fixed typo in NERD_tree.txt
2014-06-26 22:53:21 +01:00
Martin Grenfell
9e54c48086 Merge pull request #299 from tophsic/master
Fix typo
2014-06-26 22:52:45 +01:00
Martin Grenfell
8b48413155 rename NERDTreeWildIgnore option and refactor the usage of it
Rename it to the more intention revealing NERDTreeRespectWildIgnore.

Use it directly in the `globpath()` call rather than surrounding if
statement. Its subjective, but I find this clearer.

Add an initializer for the option.
2014-06-26 10:02:42 +01:00
Martin Grenfell
186abb84c1 Merge pull request #303 from amarshall/wildignore
Add option to respect wildignore
2014-06-26 09:48:39 +01:00
Martin Grenfell
dd8fe4bf69 Merge pull request #274 from an1zhegorodov/master
Fix help mistake
2014-06-26 09:30:48 +01:00
Martin Grenfell
23d2d19846 Merge pull request #331 from jinnko/add-bookmarks-sort-flag
Add flag to disable/enable bookmark sorting
2014-06-26 09:27:58 +01:00
Jaeho Shin
43842e0de5 Option for mixing dot files when sorting
NERDTree can now optionally ignore the dot at the beginning of hidden
filenames for sorting to show them next to normal files if
`g:NERDTreeSortHiddenFirst` is set to 0.  (By default it's set to 1 to
preserve the current behavior.)  This is just like what GNU ls does when
`LC_COLLATE` environment variable is set to `en_US`.
2014-06-09 23:11:44 -07:00
Jinn Koriech
e38d8a8340 Add flag to disable/enable bookmark sorting
The bookmarks are normally sorted, however with a newly introduced
flag this can be disabled.
2014-04-24 15:51:55 +01:00
Andrew Marshall
a50c571929 Add option to respect wildignore 2013-12-07 00:10:46 -05:00
Christophe Sicard
4f48af0cb4 Fix typo 2013-11-06 15:41:25 +01:00
Anton Nizhegorodov
5b51f9d1ba Fix help mistake 2013-07-22 00:29:03 +03:00
Stephan Klinger
2ebe28468b Fixed typo in NERD_tree.txt 2013-05-28 00:20:15 +03:00
Volodymyr Medvid
21af5e0abd fix spelling in documentation 2013-05-14 16:39:46 +03:00
pendulm
6ef67a2d8e Add correspoding close action to cascade open single child dir 2013-04-22 23:39:26 +08:00
pendulm
60683f1cce Fix typo Casade to Cascade 2013-04-22 23:35:15 +08:00
Techlive Zheng
072d46880a Add a NERDTreeCWD command to change tree root to CWD 2012-11-05 19:11:44 +08:00
ZeusTheTrueGod
0a16b24268 Better flow for renaming and deleting files
Previously when you delete or moved a file via
md or mm commands the NERDTree was asking you about what to do
with the remaining buffer of the just deleted or moved file. I
always press 'y' in this cases so I've decided to add a new parameter,
NERDTreeAutoDeleteBuffer which you can set to 1 in order to skip
this confirmation.
2012-08-26 11:56:45 +00:00
Martin Grenfell
a1433c485e update the doc for NERDTreeCasadeOpenSingleChildDir 2012-07-05 15:56:11 +01:00
Martin Grenfell
b64f4428c1 default NERDTreeCasadeOpenSingleChildDir to 1 2012-07-05 15:51:13 +01:00
pendulm
29e687978b add option NERDTreeCasadeOpenSingleChildDir and function
TreeDirNode.openAlong for Issues #179.
2012-07-05 22:26:57 +08:00
Martin Grenfell
54fab2f2e5 add dir and file flags to NERDTreeIgnore regexes
This allows users to specify whether each regex in NERDTreeIgnore should
apply to only files or only dirs.
2012-01-05 11:41:51 +00:00
Martin Grenfell
33a64260cd add NERDTreeCustomIgnoreFilter hook
this gives users a chance to filter out nodes using whatever logic they
please
2012-01-04 11:13:03 +00:00
Martin Grenfell
73e2d8ca7e update the doc for the new key api functionality 2012-01-03 16:05:19 +00:00
Martin Grenfell
205367ab3f update changelog/credits and bump to version 4.2.0 2011-12-28 13:16:57 +00:00
Martin Grenfell
4411344f7c update the doc for the new NERDTreeFind behaviour 2011-12-27 22:22:10 +00:00
Min-Young Wu
dcccd0e532 Defaulting bookmark name to file/dir name
Note that for directories, there is a trailing slash
2011-12-21 13:15:56 +00:00
Cam Thompson
b9e970d934 Merge branch 'master' of git://github.com/scrooloose/nerdtree
Conflicts:
	doc/NERD_tree.txt
2011-02-27 20:45:22 -05:00
Cam Thompson
999ba49857 merge hide bookmarks and press ? options 2011-02-27 20:36:06 -05:00
Cam Thompson
2d17132f48 add bookmarks and press help documentation 2011-02-25 13:14:49 -05:00
Marcin Kulik
8accb0978e Make tree style (|+~ or arrows) configurable 2011-02-23 18:40:11 +01:00
marty
7650cdc662 update credits/changelog 2010-11-20 18:04:39 +13:00
marty
153041ac93 switch to version 4.1.0 2009-12-01 22:20:53 +13:00
marty
68cb5fc2eb update changelog and credits 2009-12-01 22:19:43 +13:00
marty
b047d7f312 put the open-in-new-tab logic in the models, make NERDTreeQuitOnOpen effect T and t 2009-11-24 00:11:02 +13:00
marty
4b566f153f add NERDTreeFind command and handling code 2009-11-22 19:29:16 +13:00
marty
c864c6e463 bugfix for NERDTreeMirror
when the user was prompted to choose a tree to mirror, it would mirror
the wrong one
2009-10-09 18:46:33 +13:00
marty
bc55f3dda8 fix a typo in the doc 2009-10-09 15:54:57 +13:00
marty
39a3a78729 update changelog/credits 2009-10-09 15:54:46 +13:00
marty
3837ea85e0 change my email to gmail 2009-10-09 14:46:40 +13:00
marty
e2265ec3b3 update the changelog 2009-09-06 13:43:54 +12:00
marty
5ba3b3a5a8 update the doc 2009-09-06 13:43:47 +12:00
marty
6a513e4340 remove some old code left over for the ! mapping 2009-09-06 12:19:32 +12:00
marty
1ea2a0c29b update doc RE menu 2009-09-06 11:27:36 +12:00
marty
36e4402550 update the API doc 2009-09-04 00:36:01 +12:00
marty
7051977808 updates to the doc 2009-08-22 01:57:45 +12:00
marty
5e9635dfa4 update some of the old fs menu doc for the new menu system 2009-08-22 01:54:05 +12:00
marty
1080246af9 add some doc for the new API 2009-08-22 01:26:47 +12:00
marty
59257d7a3a remove the old api functions 2009-08-12 00:55:12 +12:00
marty
236d20946c correct a typo in the changelog 2009-08-11 16:10:01 +12:00
marty
a796715ac1 add A mapping to maximize/restore tree window size
this commit is a modified patch from Guillaume Duranceau
2009-08-11 16:09:51 +12:00
Martin Grenfell
e164980d84 fix a bug where the script ignored dirs ending in a dot 2009-07-18 00:55:01 +12:00
Martin Grenfell
71ebe27a8d fix a bug with secondary nerd trees and NERDTreeQuitOnOpen 2009-07-18 00:48:32 +12:00
Martin Grenfell
e7ebee3084 switch to version 3.1.1 2009-06-07 21:36:59 +12:00
Martin Grenfell
1239f78baf update changelog 2009-06-07 21:36:00 +12:00
Martin Grenfell
9b12953343 add a help file entry for the cd mapping 2009-06-02 11:09:33 +12:00
Martin Grenfell
84f9793231 fix some help tags 2009-05-29 14:23:58 +12:00
Martin Grenfell
1f46ecf4b8 update changelog 2009-03-12 09:45:18 +13:00
Martin Grenfell
3796a8799a map '<CR>' to the same as 'o' 2009-03-06 15:57:51 +13:00
Martin Grenfell
faf1459ce5 minor doc fix 2009-01-27 18:58:26 +13:00
Martin Grenfell
02751f4d11 update changelog and credits 2009-01-26 22:52:52 +13:00
Martin Grenfell
7522cbf4f0 add g:NERDTreeStatusline option
allows the statusline to be customised for the nerd tree window
2009-01-21 23:03:45 +13:00
Martin Grenfell
40374e5056 add doc for the vertical split maps 2009-01-14 16:18:46 +13:00
Martin Grenfell
4e4fb179e7 correct a help tag 2009-01-14 16:04:26 +13:00
Martin Grenfell
7b59186dfe update change log and credits 2009-01-12 22:40:59 +13:00
Martin Grenfell
495e906169 update changelog 2009-01-09 18:14:44 +13:00
Martin Grenfell
3d2bf2d9ac fix a bug when doing :NERDTreeMirror without 'hidden set 2009-01-09 15:23:57 +13:00
Martin Grenfell
2f4d1b93e8 make the q mapping work with secondary trees 2009-01-09 14:46:49 +13:00
Martin Grenfell
1b13fb05ea add a note to the changelog 2009-01-09 11:39:31 +13:00
Martin Grenfell
f90da509e1 updates to the doc
*remove the change log prior to v3.0.0
*remove the todo section
*change "about the author" to "about" and put the github/vim.org project
urls in it
2009-01-09 11:27:41 +13:00
Martin Grenfell
c8afb6d92d fix a bug where :NERDTreeToggle was broken without :set hidden 2009-01-09 09:40:23 +13:00
Martin Grenfell
8f7e2bb98a update changelog for version 3.0.0 2008-12-27 14:43:45 +13:00
Martin Grenfell
39fc42d1cf change the H mapping (toggle hidden files) to I 2008-12-27 11:34:15 +13:00
Martin Grenfell
7f6603ea4a update the doc for the e mapping 2008-12-25 10:23:42 +13:00
Martin Grenfell
4f5599e275 update the 'features' blurb in the doc intro 2008-12-24 18:05:16 +13:00
Martin Grenfell
c9c67b5b67 add a help tag for :NERDTreeClose 2008-12-24 14:23:39 +13:00
Martin Grenfell
3803db5555 add doc for :NERDTreeMirror 2008-12-24 14:09:09 +13:00
Martin Grenfell
d3b2258acb update doc for hacking nerd tree 2008-12-22 23:33:38 +13:00
Martin Grenfell
56b5446eaf change the <tab> mapping to i 2008-12-17 23:28:20 +13:00
Martin Grenfell
88020835d6 make the nerd tree only appear on the left or right
remove "top" and "bottom" as valid settings for NERDTreeWinPos
2008-12-17 23:22:43 +13:00