MCPcopy Index your code
hub / github.com/jetify-com/devbox / EnsureAbsolutePaths

Function EnsureAbsolutePaths

internal/fileutil/fileutil.go:83–97  ·  view source on GitHub ↗
(paths []string)

Source from the content-addressed store, hash-verified

81}
82
83func EnsureAbsolutePaths(paths []string) ([]string, error) {
84 wd, err := os.Getwd()
85 if err != nil {
86 return nil, errors.WithStack(err)
87 }
88 absPaths := make([]string, len(paths))
89 for i, path := range paths {
90 if filepath.IsAbs(path) {
91 absPaths[i] = path
92 } else {
93 absPaths[i] = filepath.Join(wd, path)
94 }
95 }
96 return absPaths, nil
97}

Callers 2

secretsDownloadCmdFunction · 0.92
secretsUploadCmdFunction · 0.92

Calls

no outgoing calls

Tested by

no test coverage detected