feat(manage): added user events when operations finish. Fixes #135

This commit is contained in:
Folke Lemaitre 2022-12-24 11:55:42 +01:00
parent 3352fc6265
commit a36d506393
No known key found for this signature in database
GPG key ID: 41F8B1FBACAE2040
4 changed files with 39 additions and 6 deletions

View file

@ -139,7 +139,10 @@ end
---@param cb? fun()
function Runner:wait(cb)
if #self._running == 0 then
return cb and cb()
if cb then
cb()
end
return self
end
if cb then
@ -150,6 +153,7 @@ function Runner:wait(cb)
vim.wait(10)
end
end
return self
end
return Runner