MCPcopy
hub / github.com/colbymchenry/codegraph / realpath

Function realpath

src/sync/worktree.ts:147–153  ·  view source on GitHub ↗

Resolve symlinks where possible so tmp/realpath quirks don't break equality.

(p: string)

Source from the content-addressed store, hash-verified

145
146/** Resolve symlinks where possible so tmp/realpath quirks don't break equality. */
147function realpath(p: string): string {
148 try {
149 return fs.realpathSync(path.resolve(p));
150 } catch {
151 return path.resolve(p);
152 }
153}

Callers 3

gitWorktreeRootFunction · 0.85
gitCommonDirFunction · 0.85

Calls 1

resolveMethod · 0.80

Tested by

no test coverage detected