mirror of
https://github.com/sourcegit-scm/sourcegit
synced 2025-05-22 20:54:59 +00:00
feature: git command logs
Signed-off-by: leo <longshuang@msn.cn>
This commit is contained in:
parent
928a0ad3c5
commit
8b39df32cc
101 changed files with 1040 additions and 573 deletions
|
@ -302,17 +302,20 @@ namespace SourceGit.ViewModels
|
|||
var picker = await storageProvider.OpenFolderPickerAsync(options);
|
||||
if (picker.Count == 1)
|
||||
{
|
||||
var log = _repo.CreateLog("Save as Patch");
|
||||
var succ = false;
|
||||
for (var i = 0; i < selected.Count; i++)
|
||||
{
|
||||
var saveTo = GetPatchFileName(picker[0].Path.LocalPath, selected[i], i);
|
||||
succ = await Task.Run(() => new Commands.FormatPatch(_repo.FullPath, selected[i].SHA, saveTo).Exec());
|
||||
succ = await Task.Run(() => new Commands.FormatPatch(_repo.FullPath, selected[i].SHA, saveTo).Use(log).Exec());
|
||||
if (!succ)
|
||||
break;
|
||||
}
|
||||
|
||||
if (succ)
|
||||
App.SendNotification(_repo.FullPath, App.Text("SaveAsPatchSuccess"));
|
||||
|
||||
log.Complete();
|
||||
}
|
||||
}
|
||||
catch (Exception exception)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue