MCPcopy Index your code
hub / github.com/go-git/go-git / unmarshalSubmodules

Function unmarshalSubmodules

config/config.go:396–409  ·  view source on GitHub ↗
(fc *format.Config, submodules map[string]*Submodule)

Source from the content-addressed store, hash-verified

394}
395
396func unmarshalSubmodules(fc *format.Config, submodules map[string]*Submodule) {
397 s := fc.Section(submoduleSection)
398 for _, sub := range s.Subsections {
399 m := &Submodule{}
400 m.unmarshal(sub)
401
402 if err := m.Validate(); errors.Is(err, ErrModuleBadPath) ||
403 errors.Is(err, ErrModuleBadName) {
404 continue
405 }
406
407 submodules[m.Name] = m
408 }
409}
410
411func (c *Config) unmarshalBranches() error {
412 bs := c.Raw.Section(branchSection)

Callers 2

UnmarshalMethod · 0.85
UnmarshalMethod · 0.85

Calls 4

unmarshalMethod · 0.95
ValidateMethod · 0.95
SectionMethod · 0.80
IsMethod · 0.80

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…