Merge pull request #50 from sdewald/master
Fix for issue #22 -- "FUNCTION: NERDTreeAddNode() cannot handle paths with spaces"
This commit is contained in:
commit
bf73470723
@ -57,7 +57,7 @@ function! NERDTreeAddNode()
|
|||||||
let newNodeName = input("Add a childnode\n".
|
let newNodeName = input("Add a childnode\n".
|
||||||
\ "==========================================================\n".
|
\ "==========================================================\n".
|
||||||
\ "Enter the dir/file name to be created. Dirs end with a '/'\n" .
|
\ "Enter the dir/file name to be created. Dirs end with a '/'\n" .
|
||||||
\ "", curDirNode.path.str({'format': 'Glob'}) . g:NERDTreePath.Slash())
|
\ "", curDirNode.path.str() . g:NERDTreePath.Slash())
|
||||||
|
|
||||||
if newNodeName ==# ''
|
if newNodeName ==# ''
|
||||||
call s:echo("Node Creation Aborted.")
|
call s:echo("Node Creation Aborted.")
|
||||||
|
@ -2029,7 +2029,7 @@ function! s:Path.copy(dest)
|
|||||||
|
|
||||||
let dest = s:Path.WinToUnixPath(a:dest)
|
let dest = s:Path.WinToUnixPath(a:dest)
|
||||||
|
|
||||||
let cmd = g:NERDTreeCopyCmd . " " . self.str() . " " . dest
|
let cmd = g:NERDTreeCopyCmd . " " . escape(self.str(), s:escape_chars) . " " . escape(dest, s:escape_chars)
|
||||||
let success = system(cmd)
|
let success = system(cmd)
|
||||||
if success != 0
|
if success != 0
|
||||||
throw "NERDTree.CopyError: Could not copy ''". self.str() ."'' to: '" . a:dest . "'"
|
throw "NERDTree.CopyError: Could not copy ''". self.str() ."'' to: '" . a:dest . "'"
|
||||||
|
Loading…
x
Reference in New Issue
Block a user