MCPcopy
hub / github.com/AutoMaker-Org/automaker / copyFile

Function copyFile

libs/platform/src/secure-fs.ts:257–264  ·  view source on GitHub ↗
(src: string, dest: string, mode?: number)

Source from the content-addressed store, hash-verified

255 * Wrapper around fs.copyFile that validates both paths first
256 */
257export async function copyFile(src: string, dest: string, mode?: number): Promise<void> {
258 const validatedSrc = validatePath(src);
259 const validatedDest = validatePath(dest);
260 return executeWithRetry(
261 () => fs.copyFile(validatedSrc, validatedDest, mode),
262 `copyFile(${src}, ${dest})`
263 );
264}
265
266/**
267 * Wrapper around fs.appendFile that validates path first

Callers

nothing calls this directly

Calls 2

validatePathFunction · 0.85
executeWithRetryFunction · 0.85

Tested by

no test coverage detected