From 25207ceeaec831af201d33b5b310cfbeef10f62b Mon Sep 17 00:00:00 2001 From: Michael Pakhantsov Date: Thu, 13 Mar 2025 15:17:06 +0200 Subject: [PATCH] Explicitly provided fully qualified reference for the git branch, becase can be exists a tag and a branch with identical names Fix push command for branch deletion Updated the `push` command to use `--delete refs/heads/{name}` instead of `--delete {name}` for clearer branch reference when deleting a remote branch. --- src/Commands/Branch.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Commands/Branch.cs b/src/Commands/Branch.cs index 391aeeb2..d56dfa97 100644 --- a/src/Commands/Branch.cs +++ b/src/Commands/Branch.cs @@ -62,7 +62,7 @@ if (exists) { cmd.SSHKey = new Config(repo).Get($"remote.{remote}.sshkey"); - cmd.Args = $"push {remote} --delete {name}"; + cmd.Args = $"push {remote} --delete refs/heads/{name}"; } else {