mirror of
https://github.com/junegunn/vim-plug.git
synced 2026-10-08 04:54:35 +08:00
Allow cloning into an empty directory (#782)
Close #766 We can rely on git to check if the destination directory is empty.
This commit is contained in:
1 parent
7f8fdd0444
commit
b6050d6f03
2 files changed
+14
-2
No files matched your search
@@ -1331,7 +1331,7 @@ while 1 " Without TCO, Vim stack is bound to explode
|
||||
|
||||
let name = keys(s:update.todo)[0]
|
||||
let spec = remove(s:update.todo, name)
|
||||
let new = !isdirectory(spec.dir)
|
||||
let new = empty(globpath(spec.dir, '.git', 1))
|
||||
|
||||
call s:log(new ? '+' : '*', name, pull ? 'Updating ...' : 'Installing ...')
|
||||
redraw
|
||||
|
||||
Reference in new issue
Block a user