Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
Merge commit '890bf2d8f8529292c5c5b6e75e0808d5ad77c9b6' as 'bundle/ne…
…rdtree'
  • Loading branch information
tao committed Feb 20, 2019
2 parents f1679ad + 890bf2d commit 27a533a
Show file tree
Hide file tree
Showing 28 changed files with 7,670 additions and 0 deletions.
28 changes: 28 additions & 0 deletions bundle/nerdtree/.github/ISSUE_TEMPLATE.md
@@ -0,0 +1,28 @@
<!--- To assist in resolving your issue, provide as much information as possible. -->

### Environment
<!--- Describe your Vim/NERDTree setup. -->

* Operating System:
* Vim version `:version`:
* NERDTree version `git rev-parse --short HEAD`:
* NERDTree settings applied in your vimrc, if any:
```vim
```
### Process
<!--- List the steps that will recreate the issue. -->
1.
### Current Result
<!--- Describe what you you currently experience from this process. -->
### Expected Result
<!--- Describe what you would have expected from this process. -->
### Screenshot(s)
### Possible Fix
<!--- If you have explored the code, share what you've found. -->
3 changes: 3 additions & 0 deletions bundle/nerdtree/.gitignore
@@ -0,0 +1,3 @@
*~
*.swp
tags
179 changes: 179 additions & 0 deletions bundle/nerdtree/CHANGELOG
@@ -0,0 +1,179 @@
Next
- Fix broken "t" and "T" mappings, tabs now open at end (lifecrisis) #759
- Update doc with already existing mapping variables (asnr) #699
- Fix the broken g:NERDTreeBookmarksSort setting (lifecrisis) #696
- Correct NERDTreeIgnore pattern in doc (cntoplolicon) #648
- Remove empty segments when splitting path (sooth-sayer) #574
- Suppress autocmds less agressively (wincent) #578 #691
- Add an Issues template to ask for more info initially.
- Fix markdown headers in readme (josephfrazier) #676
- Don't touch @o and @h registers when rendering
- Fix bug with files and directories with dollar signs (alegen) #649
- Reuse/reopen existing window trees where possible #244
- Remove NERDTree.previousBuf()
- Change color of arrow (Leeiio) #630
- Improved a tip in README.markdown (ggicci) #628
- Shorten delete confimration of empty directory to 'y' (mikeperri) #530
- Fix API call to open directory tree in window (devm33) #533
- Change default arrows on non-Windows platforms (gwilk) #546
- Update to README - combine cd and git clone (zwhitchcox) #584
- Update to README - Tip: start NERDTree when vim starts (therealplato) #593
- Escape filename when moving an open buffer (zacharyvoase) #595
- Fixed incorrect :helptags command in README (curran) #619
- Fixed incomplete escaping of folder arrows (adityanatraj) #548
- Added NERDTreeCascadeSingleChildDir option (juanibiapina) #558
- Replace strchars() with backward compatible workaround.
- Add support for copy command in Windows (SkylerLipthay) #231
- Fixed typo in README.markdown - :Helptags -> :helptags
- Rename "primary" and "secondary" trees to "tab" and "window" trees.
- Move a bunch of buffer level variables into the NERDTree and UI classes.
- Display cascading dirs on one line to save vertical/horizontal space (@matt-gardner: brainstorming/testing)
- Remove the old style UI - Remove 'NERDTreeDirArrows' option.
- On windows default to + and ~ for expand/collapse directory symbols.
- Lots more refactoring. Move a bunch of b: level vars into b:NERDTree and friends.

5.0.0
- Refactor the code significantly:
* Break the classes out into their own files.
* Make the majority of the code OO - previously large parts were
effectively a tangle of "global" methods.
- Add an API to assign flags to nodes. This allows VCS plugins like
https://github.com/Xuyuanp/nerdtree-git-plugin to exist. Thanks to
Xuyuanp for helping design/test/build said API.
- add 'scope' argument to the key map API see :help NERDTreeAddKeyMap()
- add magic [[dir]] and [[file]] flags to NERDTreeIgnore
- add support for custom path filters. See :help NERDTreeAddPathFilter()
- add path listener API. See :help NERDTreePathListenerAPI.
- expand the fs menu functionality to list file properties (PhilRunninger,
apbarrero, JESii)
- make bookmarks work with `~` home shortcuts (hiberabyss)
- show OSX specific fsmenu options in regular vim on mac (evindor)
- make dir arrow icons configurable (PickRelated)
- optimise node sorting performance when opening large dirs (vtsang)
- make the root note render prettier by truncating it at a path slash (gcmt)
- remove NERDChristmasTree option - its always christmas now
- add "cascade" open and closing for dirs containing only another single
dir. See :help NERDTreeCascadeOpenSingleChildDir (pendulm)

Many other fixes, doc updates and contributions from:
actionshrimp
SchDen
egalpin
cperl82 - many small fixes
toiffel
WoLpH
handcraftedbits
devmanhinton
xiaodili
zhangoose
gastropoda
mixvin
alvan
lucascaton
kelaban
shanesmith
staeff
pendulm
stephenprater
franksort
agrussellknives
AndrewRadev
Twinside

4.2.0
- Add NERDTreeDirArrows option to make the UI use pretty arrow chars
instead of the old +~| chars to define the tree structure (sickill)
- shift the syntax highlighting out into its own syntax file (gnap)
- add some mac specific options to the filesystem menu - for macvim
only (andersonfreitas)
- Add NERDTreeMinimalUI option to remove some non functional parts of the
nerdtree ui (camthompson)
- tweak the behaviour of :NERDTreeFind - see :help :NERDTreeFind for the
new behaviour (benjamingeiger)
- if no name is given to :Bookmark, make it default to the name of the
target file/dir (minyoung)
- use 'file' completion when doing copying, create, and move
operations (EvanDotPro)
- lots of misc bug fixes (paddyoloughlin, sdewald, camthompson, Vitaly
Bogdanov, AndrewRadev, mathias, scottstvnsn, kml, wycats, me RAWR!)

4.1.0
features:
- NERDTreeFind to reveal the node for the current buffer in the tree,
see |NERDTreeFind|. This effectively merges the FindInNERDTree plugin (by
Doug McInnes) into the script.
- make NERDTreeQuitOnOpen apply to the t/T keymaps too. Thanks to Stefan
Ritter and Rémi Prévost.
- truncate the root node if wider than the tree window. Thanks to Victor
Gonzalez.

bugfixes:
- really fix window state restoring
- fix some win32 path escaping issues. Thanks to Stephan Baumeister, Ricky,
jfilip1024, and Chris Chambers

4.0.0
- add a new programmable menu system (see :help NERDTreeMenu).
- add new APIs to add menus/menu-items to the menu system as well as
custom key mappings to the NERD tree buffer (see :help NERDTreeAPI).
- removed the old API functions
- added a mapping to maximize/restore the size of nerd tree window, thanks
to Guillaume Duranceau for the patch. See :help NERDTree-A for details.

- fix a bug where secondary nerd trees (netrw hijacked trees) and
NERDTreeQuitOnOpen didnt play nicely, thanks to Curtis Harvey.
- fix a bug where the script ignored directories whose name ended in a dot,
thanks to Aggelos Orfanakos for the patch.
- fix a bug when using the x mapping on the tree root, thanks to Bryan
Venteicher for the patch.
- fix a bug where the cursor position/window size of the nerd tree buffer
wasnt being stored on closing the window, thanks to Richard Hart.
- fix a bug where NERDTreeMirror would mirror the wrong tree

3.1.1
- fix a bug where a non-listed no-name buffer was getting created every
time the tree windows was created, thanks to Derek Wyatt and owen1
- make <CR> behave the same as the 'o' mapping
- some helptag fixes in the doc, thanks strull
- fix a bug when using :set nohidden and opening a file where the previous
buf was modified. Thanks iElectric
- other minor fixes

3.1.0
New features:
- add mappings to open files in a vsplit, see :help NERDTree-s and :help
NERDTree-gs
- make the statusline for the nerd tree window default to something
hopefully more useful. See :help 'NERDTreeStatusline'
Bugfixes:
- make the hijack netrw functionality work when vim is started with "vim
<some dir>" (thanks to Alf Mikula for the patch).
- fix a bug where the CWD wasnt being changed for some operations even when
NERDTreeChDirMode==2 (thanks to Lucas S. Buchala)
- add -bar to all the nerd tree :commands so they can chain with other
:commands (thanks to tpope)
- fix bugs when ignorecase was set (thanks to nach)
- fix a bug with the relative path code (thanks to nach)
- fix a bug where doing a :cd would cause :NERDTreeToggle to fail (thanks nach)


3.0.1
Bugfixes:
- fix bugs with :NERDTreeToggle and :NERDTreeMirror when 'hidden
was not set
- fix a bug where :NERDTree <path> would fail if <path> was relative and
didnt start with a ./ or ../ Thanks to James Kanze.
- make the q mapping work with secondary (:e <dir> style) trees,
thanks to jamessan
- fix a bunch of small bugs with secondary trees

More insane refactoring.

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
13 changes: 13 additions & 0 deletions bundle/nerdtree/LICENCE
@@ -0,0 +1,13 @@
DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE
Version 2, December 2004

Copyright (C) 2004 Sam Hocevar <sam@hocevar.net>

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.
96 changes: 96 additions & 0 deletions bundle/nerdtree/README.markdown
@@ -0,0 +1,96 @@
The NERDTree
=============

Introduction
------------

The NERDTree is a file system explorer for the Vim editor. Using this plugin,
users can visually browse complex directory hierarchies, quickly open files for
reading or editing, and perform basic file system operations.

This plugin can also be extended with custom mappings using a special API. The
details of this API and of other NERDTree features are described in the
included documentation.

![NERDTree Screenshot](https://github.com/scrooloose/nerdtree/raw/master/screenshot.png)

Installation
------------

#### [pathogen.vim](https://github.com/tpope/vim-pathogen)

git clone https://github.com/scrooloose/nerdtree.git ~/.vim/bundle/nerdtree

Then reload Vim, run `:helptags ~/.vim/bundle/nerdtree/doc/` or `:Helptags`, and check out `:help NERDTree.txt`.


#### [apt-vim](https://github.com/egalpin/apt-vim)

apt-vim install -y https://github.com/scrooloose/nerdtree.git

F.A.Q.
------

> Is there any support for `git` flags?
Yes, install [nerdtree-git-plugin](https://github.com/Xuyuanp/nerdtree-git-plugin).

---

> Can I have the nerdtree on every tab automatically?
Nope. If this is something you want then chances are you aren't using tabs and
buffers as they were intended to be used. Read this
http://stackoverflow.com/questions/102384/using-vims-tabs-like-buffers

If you are interested in this behaviour then consider [vim-nerdtree-tabs](https://github.com/jistr/vim-nerdtree-tabs)

---
> How can I open a NERDTree automatically when vim starts up?
Stick this in your vimrc: `autocmd vimenter * NERDTree`

---
> How can I open a NERDTree automatically when vim starts up if no files were specified?
Stick this in your vimrc:

autocmd StdinReadPre * let s:std_in=1
autocmd VimEnter * if argc() == 0 && !exists("s:std_in") | NERDTree | endif

Note: Now start vim with plain `vim`, not `vim .`

---
> How can I open NERDTree automatically when vim starts up on opening a directory?
autocmd StdinReadPre * let s:std_in=1
autocmd VimEnter * if argc() == 1 && isdirectory(argv()[0]) && !exists("s:std_in") | exe 'NERDTree' argv()[0] | wincmd p | ene | endif

This window is tab-specific, meaning it's used by all windows in the tab. This trick also prevents NERDTree from hiding when first selecting a file.

---
> How can I map a specific key or shortcut to open NERDTree?
Stick this in your vimrc to open NERDTree with `Ctrl+n` (you can set whatever key you want):

map <C-n> :NERDTreeToggle<CR>

---
> How can I close vim if the only window left open is a NERDTree?
Stick this in your vimrc:

autocmd bufenter * if (winnr("$") == 1 && exists("b:NERDTree") && b:NERDTree.isTabTree()) | q | endif

---
> Can I have different highlighting for different file extensions?
See here: https://github.com/scrooloose/nerdtree/issues/433#issuecomment-92590696

---
> How can I change default arrows?
Use these variables in your vimrc. Note that below are default arrow symbols

let g:NERDTreeDirArrowExpandable = '▸'
let g:NERDTreeDirArrowCollapsible = '▾'

0 comments on commit 27a533a

Please sign in to comment.