MCPcopy Index your code
hub / github.com/Waishnav/devspace / resolveAllowedPath

Function resolveAllowedPath

src/roots.ts:43–46  ·  view source on GitHub ↗
(inputPath: string, cwd: string, allowedRoots: string[])

Source from the content-addressed store, hash-verified

41}
42
43export function resolveAllowedPath(inputPath: string, cwd: string, allowedRoots: string[]): string {
44 const absolutePath = resolve(cwd, inputPath);
45 return assertAllowedPath(absolutePath, allowedRoots);
46}

Callers 8

roots.test.tsFile · 0.85
resolvePathMethod · 0.85
readFileToolFunction · 0.85
writeFileToolFunction · 0.85
editFileToolFunction · 0.85
grepFilesToolFunction · 0.85
findFilesToolFunction · 0.85
listDirectoryToolFunction · 0.85

Calls 1

assertAllowedPathFunction · 0.85

Tested by

no test coverage detected