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

Method Init

submodule.go:330–340  ·  view source on GitHub ↗
(overwrite bool)

Source from the content-addressed store, hash-verified

328}
329
330func (sub *Submodule) Init(overwrite bool) error {
331 runtime.LockOSThread()
332 defer runtime.UnlockOSThread()
333
334 ret := C.git_submodule_init(sub.ptr, cbool(overwrite))
335 runtime.KeepAlive(sub)
336 if ret < 0 {
337 return MakeGitError(ret)
338 }
339 return nil
340}
341
342func (sub *Submodule) Sync() error {
343 runtime.LockOSThread()

Callers

nothing calls this directly

Calls 2

cboolFunction · 0.85
MakeGitErrorFunction · 0.85

Tested by

no test coverage detected