MCPcopy Create free account
hub / github.com/dagger/dagger / Equals

Method Equals

core/modtree.go:756–770  ·  view source on GitHub ↗
(ctx context.Context, other ModTreePath)

Source from the content-addressed store, hash-verified

754}
755
756func (p ModTreePath) Equals(ctx context.Context, other ModTreePath) (result bool) {
757 defer func() {
758 debugTrace(ctx, "%v.Equals(%v) -> %v", p, other, result)
759 }()
760 if len(p) != len(other) {
761 return false
762 }
763 for i := range p {
764 if gqlFieldName(p[i]) != gqlFieldName(other[i]) {
765 debugTrace(ctx, "%v.Equals(%v): %q != %q -> NOT EQUAL", p, other, gqlFieldName(p[i]), gqlFieldName(other[i]))
766 return false
767 }
768 }
769 return true
770}
771
772func (p ModTreePath) Glob(ctx context.Context, pattern string) (bool, error) {
773 // Normalize both pattern and path to CLI case (kebab-case) for consistent matching

Callers 1

ContainsMethod · 0.95

Calls 2

debugTraceFunction · 0.85
gqlFieldNameFunction · 0.70

Tested by

no test coverage detected