Ensure jobstart on_exit runs when waiting

Resolves: https://github.com/tpope/vim-fugitive/issues/1857
This commit is contained in:
Tim Pope
2021-10-08 19:03:36 -04:00
parent bcf7478e6b
commit ae93dbea2e

View File

@@ -263,6 +263,9 @@ function! fugitive#Wait(job_or_jobs, ...) abort
if exists('*jobwait')
call map(copy(jobs), 'chanclose(v:val, "stdin")')
call jobwait(jobs, timeout_ms)
if len(jobs) && has('nvim-0.5')
sleep 1m
endif
else
let sleep = has('patch-8.2.2366') ? 'sleep! 1m' : 'sleep 1m'
for job in jobs