feature: add Wait for action done option to control whether or not to wait for the custom action execution to complete (#951)

Signed-off-by: leo <longshuang@msn.cn>
This commit is contained in:
leo 2025-02-11 14:34:14 +08:00
parent 10fba08e43
commit af20ab2448
No known key found for this signature in database
7 changed files with 49 additions and 3 deletions

View file

@ -28,7 +28,11 @@ namespace SourceGit.ViewModels
return Task.Run(() =>
{
Commands.ExecuteCustomAction.Run(_repo.FullPath, CustomAction.Executable, _args, SetProgressDescription);
if (CustomAction.WaitForExit)
Commands.ExecuteCustomAction.RunAndWait(_repo.FullPath, CustomAction.Executable, _args, SetProgressDescription);
else
Commands.ExecuteCustomAction.Run(_repo.FullPath, CustomAction.Executable, _args);
CallUIThread(() => _repo.SetWatcherEnabled(true));
return true;
});