mirror of
https://fastgit.cc/github.com/sourcegit-scm/sourcegit
synced 2026-04-22 05:40:43 +08:00
code_review: PR #1093
Merge deleting branch and tag on remote into `SourceGit.Commands.Push(repo, remote, refname, isDelete)` Signed-off-by: leo <longshuang@msn.cn>
This commit is contained in:
@@ -96,7 +96,7 @@ namespace SourceGit.ViewModels
|
||||
foreach (var remote in remotes)
|
||||
{
|
||||
SetProgressDescription($"Pushing tag to remote {remote.Name} ...");
|
||||
new Commands.Push(_repo.FullPath, remote.Name, _tagName, false).Exec();
|
||||
new Commands.Push(_repo.FullPath, remote.Name, $"refs/tags/{_tagName}", false).Exec();
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -43,13 +43,14 @@ namespace SourceGit.ViewModels
|
||||
|
||||
return Task.Run(() =>
|
||||
{
|
||||
bool succ = true;
|
||||
var succ = true;
|
||||
var tag = $"refs/tags/{Target.Name}";
|
||||
if (_pushAllRemotes)
|
||||
{
|
||||
foreach (var remote in _repo.Remotes)
|
||||
{
|
||||
SetProgressDescription($"Pushing tag to remote {remote.Name} ...");
|
||||
succ = new Commands.Push(_repo.FullPath, remote.Name, Target.Name, false).Exec();
|
||||
succ = new Commands.Push(_repo.FullPath, remote.Name, tag, false).Exec();
|
||||
if (!succ)
|
||||
break;
|
||||
}
|
||||
@@ -57,7 +58,7 @@ namespace SourceGit.ViewModels
|
||||
else
|
||||
{
|
||||
SetProgressDescription($"Pushing tag to remote {SelectedRemote.Name} ...");
|
||||
succ = new Commands.Push(_repo.FullPath, SelectedRemote.Name, Target.Name, false).Exec();
|
||||
succ = new Commands.Push(_repo.FullPath, SelectedRemote.Name, tag, false).Exec();
|
||||
}
|
||||
|
||||
CallUIThread(() => _repo.SetWatcherEnabled(true));
|
||||
|
||||
Reference in New Issue
Block a user