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

Function addRemote

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

Source from the content-addressed store, hash-verified

133}
134
135func addRemote(local, remote string) {
136 cmd := exec.Command("git", "remote", "add", "origin", remote)
137 cmd.Dir = local
138 err := cmd.Run()
139 CheckIfError(err)
140}
141
142func testExample(t *testing.T, name, dir string) {
143 arguments := append([]string{"run", dir}, args[name]...)

Callers 1

Calls 2

CheckIfErrorFunction · 0.85
CommandMethod · 0.65

Tested by

no test coverage detected