gsquash/git/pull.go
2023-12-05 19:03:27 +00:00

24 lines
370 B
Go

package git
// Pull pulls the latest changes from the remote
func (g *Git) Pull() error {
_, err := g.Execute("pull")
if err != nil {
return err
}
return nil
}
// PullMain pulls the latest changes from the remote main branch
func (g *Git) PullMain() error {
_, err := g.Execute("pull", "origin", g.MainBranch)
if err != nil {
return err
}
return nil
}