mirror of
https://github.com/jesseduffield/lazygit.git
synced 2025-05-12 21:05:48 +02:00
support setting upstream
This commit is contained in:
parent
b42202ea1c
commit
07cbae4019
6 changed files with 55 additions and 5 deletions
|
@ -1087,3 +1087,7 @@ func (c *GitCommand) IsHeadDetached() bool {
|
|||
func (c *GitCommand) DeleteRemoteBranch(remoteName string, branchName string) error {
|
||||
return c.OSCommand.RunCommand(fmt.Sprintf("git push %s --delete %s", remoteName, branchName))
|
||||
}
|
||||
|
||||
func (c *GitCommand) SetBranchUpstream(remoteName string, remoteBranchName string, branchName string) error {
|
||||
return c.OSCommand.RunCommand(fmt.Sprintf("git branch --set-upstream-to=%s/%s %s", remoteName, remoteBranchName, branchName))
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue