MCPcopy Create free account
hub / github.com/compose-spec/compose-go / Next

Method Next

tree/path.go:42–48  ·  view source on GitHub ↗

Next returns a new path by append part to the current path

(part string)

Source from the content-addressed store, hash-verified

40
41// Next returns a new path by append part to the current path
42func (p Path) Next(part string) Path {
43 if p == "" {
44 return Path(part)
45 }
46 part = strings.ReplaceAll(part, pathSeparator, "👻")
47 return Path(string(p) + pathSeparator + part)
48}
49
50func (p Path) Parts() []string {
51 return strings.Split(string(p), pathSeparator)

Callers 14

resolveRelativePathsMethod · 0.80
checkFunction · 0.80
enforceUnicityFunction · 0.80
mergeMappingsFunction · 0.80
recursiveInterpolateFunction · 0.80
omitEmptyFunction · 0.80
resolveContainerMethod · 0.80
applyNullOverridesMethod · 0.80
processExtensionsFunction · 0.80
nameServicesFunction · 0.80
transformSequenceFunction · 0.80
transformMappingFunction · 0.80

Calls 1

PathTypeAlias · 0.85

Tested by

no test coverage detected