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

Method Validate

options.go:512–518  ·  view source on GitHub ↗

Validate validates the fields and sets the default values.

(r *Repository)

Source from the content-addressed store, hash-verified

510
511// Validate validates the fields and sets the default values.
512func (o *AddOptions) Validate(r *Repository) error {
513 if o.Path != "" && o.Glob != "" {
514 return fmt.Errorf("fields Path and Glob are mutual exclusive")
515 }
516
517 return nil
518}
519
520// CommitOptions describes how a commit operation should be performed.
521type CommitOptions struct {

Callers 2

ValidateMethod · 0.45
ValidateMethod · 0.45

Calls

no outgoing calls

Tested by

no test coverage detected