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

Method Validate

options.go:748–750  ·  view source on GitHub ↗

Validate validates the fields and sets the default values. TODO: deprecate in favor of Validate(r *Repository) in v6.

(w *Worktree)

Source from the content-addressed store, hash-verified

746//
747// TODO: deprecate in favor of Validate(r *Repository) in v6.
748func (o *GrepOptions) Validate(w *Worktree) error {
749 return o.validate(w.r)
750}
751
752func (o *GrepOptions) validate(r *Repository) error {
753 if !o.CommitHash.IsZero() && o.ReferenceName != "" {

Callers

nothing calls this directly

Calls 1

validateMethod · 0.95

Tested by

no test coverage detected