From b74708613721527c25ce095085cb555fc1398548 Mon Sep 17 00:00:00 2001 From: Martin Grenfell Date: Tue, 3 Jun 2008 21:40:16 +1200 Subject: [PATCH] strip trailing slashes off copy destination --- plugin/NERD_tree.vim | 3 +++ 1 file changed, 3 insertions(+) diff --git a/plugin/NERD_tree.vim b/plugin/NERD_tree.vim index b6f2fd0..5736a9c 100644 --- a/plugin/NERD_tree.vim +++ b/plugin/NERD_tree.vim @@ -2495,6 +2495,9 @@ function! s:CopyNode() \ "", currentNode.path.Str(0)) if newNodePath != "" + "strip trailing slash + let newNodePath = substitute(newNodePath, '\/$', '', '') + let confirmed = 1 if currentNode.path.CopyingWillOverwrite(newNodePath) echo "\nWarning: copying may overwrite files! Continue? (yN)"