MCPcopy Create free account
hub / github.com/AnukarOP/claude-code-leaked / getAbsoluteAndRelativePaths

Function getAbsoluteAndRelativePaths

source code/utils/file.ts:146–155  ·  view source on GitHub ↗
(path: string | undefined)

Source from the content-addressed store, hash-verified

144}
145
146export function getAbsoluteAndRelativePaths(path: string | undefined): {
147 absolutePath: string | undefined
148 relativePath: string | undefined
149} {
150 const absolutePath = path ? expandPath(path) : undefined
151 const relativePath = absolutePath
152 ? relative(getCwd(), absolutePath)
153 : undefined
154 return { absolutePath, relativePath }
155}
156
157export function getDisplayPath(filePath: string): string {
158 // Use relative path if file is in the current working directory

Callers 1

getDisplayPathFunction · 0.85

Calls 2

expandPathFunction · 0.85
getCwdFunction · 0.85

Tested by

no test coverage detected