Print exception from post-update hook with : prefix

This commit is contained in:
Junegunn Choi
2016-10-08 23:13:36 +09:00
parent c0a83826f9
commit 5d8c4bfc1f
2 changed files with 15 additions and 1 deletions

View File

@@ -809,7 +809,11 @@ function! s:do(pull, force, todo)
if type == s:TYPE.string
if spec.do[0] == ':'
call s:load_plugin(spec)
execute spec.do[1:]
try
execute spec.do[1:]
catch
let error = v:exception
endtry
if !s:plug_window_exists()
cd -
throw 'Warning: vim-plug was terminated by the post-update hook of '.name