MCPcopy Create free account
hub / github.com/bufbuild/buf / NormalizeAndAbsolute

Function NormalizeAndAbsolute

private/pkg/normalpath/normalpath.go:115–121  ·  view source on GitHub ↗

NormalizeAndAbsolute normalizes the path and makes it absolute.

(path string)

Source from the content-addressed store, hash-verified

113
114// NormalizeAndAbsolute normalizes the path and makes it absolute.
115func NormalizeAndAbsolute(path string) (string, error) {
116 absPath, err := filepath.Abs(Unnormalize(path))
117 if err != nil {
118 return "", err
119 }
120 return Normalize(absPath), nil
121}
122
123// NormalizeAndTransformForPathType calls NormalizeAndValidate for relative
124// paths, and NormalizeAndAbsolute for absolute paths.

Callers 3

Calls 2

UnnormalizeFunction · 0.85
NormalizeFunction · 0.85

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…