MCPcopy Create free account
hub / github.com/cortexkit/magic-context / resolveFirstExisting

Function resolveFirstExisting

packages/pi-plugin/src/config/index.ts:82–84  ·  view source on GitHub ↗
(paths: string[])

Source from the content-addressed store, hash-verified

80}
81
82function resolveFirstExisting(paths: string[]): string | undefined {
83 return paths.find((path) => existsSync(path));
84}
85
86// When the shared CortexKit base is absent (migration refused on a differing
87// OpenCode/Pi pair, or not yet run), read Pi's OWN legacy file as a

Callers 2

loadPiConfigFunction · 0.85
loadPiConfigDetailedFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected