From 71542dd896515a378f17972d9b60ee988f5bce76 Mon Sep 17 00:00:00 2001 From: Junegunn Choi Date: Mon, 9 Feb 2015 12:12:50 +0900 Subject: [PATCH] Do not use --progress option when not necessary Patch suggested by @sangh. Fix #162 and #163. --- plug.vim | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/plug.vim b/plug.vim index c01e242..006ac7b 100644 --- a/plug.vim +++ b/plug.vim @@ -914,6 +914,7 @@ while 1 " Without TCO, Vim stack is bound to explode let spec = remove(s:update.todo, name) let pull = s:update.pull let new = !isdirectory(spec.dir) + let prog = s:nvim ? '--progress' : '' call s:log(new ? '+' : '*', name, pull ? 'Updating ...' : 'Installing ...') redraw @@ -923,8 +924,8 @@ while 1 " Without TCO, Vim stack is bound to explode if valid if pull call s:spawn(name, - \ printf('(git fetch --progress 2>&1 && git checkout -q %s 2>&1 && git merge --ff-only origin/%s 2>&1 && git submodule update --init --recursive 2>&1)', - \ s:shellesc(spec.branch), s:shellesc(spec.branch)), { 'dir': spec.dir }) + \ printf('(git fetch %s 2>&1 && git checkout -q %s 2>&1 && git merge --ff-only origin/%s 2>&1 && git submodule update --init --recursive 2>&1)', + \ prog, s:shellesc(spec.branch), s:shellesc(spec.branch)), { 'dir': spec.dir }) else let s:jobs[name] = { 'running': 0, 'result': 'Already installed', 'error': 0 } endif @@ -933,7 +934,8 @@ while 1 " Without TCO, Vim stack is bound to explode endif else call s:spawn(name, - \ printf('git clone --progress --recursive %s -b %s %s 2>&1', + \ printf('git clone %s --recursive %s -b %s %s 2>&1', + \ prog, \ s:shellesc(spec.uri), \ s:shellesc(spec.branch), \ s:shellesc(s:trim(spec.dir))), { 'new': 1 })