MCPcopy Create free account
hub / github.com/Houseofmvps/codesight / readFileSafe

Function readFileSafe

src/scanner.ts:218–224  ·  view source on GitHub ↗
(path: string)

Source from the content-addressed store, hash-verified

216}
217
218export async function readFileSafe(path: string): Promise<string> {
219 try {
220 return await readFile(path, "utf-8");
221 } catch {
222 return "";
223 }
224}
225
226export async function detectProject(root: string): Promise<ProjectInfo> {
227 const pkgPath = join(root, "package.json");

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected