From e164980d8457645719c669941a65e5273cd06d21 Mon Sep 17 00:00:00 2001 From: Martin Grenfell Date: Sat, 18 Jul 2009 00:55:01 +1200 Subject: [PATCH] fix a bug where the script ignored dirs ending in a dot --- doc/NERD_tree.txt | 2 ++ plugin/NERD_tree.vim | 2 +- 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/doc/NERD_tree.txt b/doc/NERD_tree.txt index 0a425c2..a54de3a 100644 --- a/doc/NERD_tree.txt +++ b/doc/NERD_tree.txt @@ -1000,6 +1000,8 @@ The latest dev versions are on github Next release: - 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. 3.1.1 - fix a bug where a non-listed no-name buffer was getting created every diff --git a/plugin/NERD_tree.vim b/plugin/NERD_tree.vim index 0286967..54996cf 100644 --- a/plugin/NERD_tree.vim +++ b/plugin/NERD_tree.vim @@ -1186,7 +1186,7 @@ function! s:TreeDirNode._initChildren(silent) "filter out the .. and . directories "Note: we must match .. AND ../ cos sometimes the globpath returns "../ for path with strange chars (eg $) - if i !~ '\.\.\/\?$' && i !~ '\.\/\?$' + if i !~ '^\.\.\/\?$' && i !~ '^\.\/\?$' "put the next file in a new node and attach it try