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

Method Status

submodule.go:385–408  ·  view source on GitHub ↗

Status returns the status of the submodules.

()

Source from the content-addressed store, hash-verified

383
384// Status returns the status of the submodules.
385func (s Submodules) Status() (SubmodulesStatus, error) {
386 var list SubmodulesStatus
387
388 var r *Repository
389 for _, sub := range s {
390 if r == nil {
391 r = sub.w.r
392 }
393
394 idx, err := r.Storer.Index()
395 if err != nil {
396 return nil, err
397 }
398
399 status, err := sub.status(idx)
400 if err != nil {
401 return nil, err
402 }
403
404 list = append(list, status)
405 }
406
407 return list, nil
408}
409
410// SubmodulesStatus contains the status for all submodiles in the worktree
411type SubmodulesStatus []*SubmoduleStatus

Callers

nothing calls this directly

Calls 2

IndexMethod · 0.65
statusMethod · 0.45

Tested by

no test coverage detected