MCPcopy
hub / github.com/kopia/kopia / getLocalFSEntry

Function getLocalFSEntry

cli/config.go:114–130  ·  view source on GitHub ↗
(ctx context.Context, path0 string)

Source from the content-addressed store, hash-verified

112}
113
114func getLocalFSEntry(ctx context.Context, path0 string) (fs.Entry, error) {
115 path, err := resolveSymlink(path0)
116 if err != nil {
117 return nil, errors.Wrap(err, "resolveSymlink")
118 }
119
120 if path != path0 {
121 log(ctx).Infof("%v resolved to %v", path0, path)
122 }
123
124 e, err := localfs.NewEntry(path)
125 if err != nil {
126 return nil, errors.Wrap(err, "can't get local fs entry")
127 }
128
129 return e, nil
130}
131
132func isWindows() bool {
133 return runtime.GOOS == "windows"

Callers 2

runMethod · 0.85
getContentToSnapshotMethod · 0.85

Calls 2

NewEntryFunction · 0.92
resolveSymlinkFunction · 0.70

Tested by

no test coverage detected