MCPcopy Create free account
hub / github.com/libgit2/git2go / Config

Method Config

repository.go:155–169  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

153}
154
155func (v *Repository) Config() (*Config, error) {
156 config := new(Config)
157
158 runtime.LockOSThread()
159 defer runtime.UnlockOSThread()
160
161 ret := C.git_repository_config(&config.ptr, v.ptr)
162 runtime.KeepAlive(v)
163 if ret < 0 {
164 return nil, MakeGitError(ret)
165 }
166
167 runtime.SetFinalizer(config, (*Config).Free)
168 return config, nil
169}
170
171// SetConfig sets the configuration file for this repository.
172//

Callers 4

TestRepositorySetConfigFunction · 0.80
TestRemoteConnectOptionFunction · 0.80
TestRemotePruneRefsFunction · 0.80
TestRemotePruneFunction · 0.80

Calls 1

MakeGitErrorFunction · 0.85

Tested by 4

TestRepositorySetConfigFunction · 0.64
TestRemoteConnectOptionFunction · 0.64
TestRemotePruneRefsFunction · 0.64
TestRemotePruneFunction · 0.64