MCPcopy Create free account
hub / github.com/go-git/go-git / setRemote

Function setRemote

_examples/common_test.go:128–133  ·  view source on GitHub ↗
(local, remote string)

Source from the content-addressed store, hash-verified

126}
127
128func setRemote(local, remote string) {
129 cmd := exec.Command("git", "remote", "set-url", "origin", remote)
130 cmd.Dir = local
131 err := cmd.Run()
132 CheckIfError(err)
133}
134
135func addRemote(local, remote string) {
136 cmd := exec.Command("git", "remote", "add", "origin", remote)

Callers 1

setEmptyRemoteFunction · 0.85

Calls 2

CheckIfErrorFunction · 0.85
CommandMethod · 0.65

Tested by

no test coverage detected