MCPcopy Create free account
hub / github.com/MoonshotAI/kimi-code / detectNativeInstall

Function detectNativeInstall

apps/kimi-code/src/cli/update/source.ts:29–37  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

27
28/** Runtime SEA detection — true when running as a packaged native binary. */
29export function detectNativeInstall(): boolean {
30 const sea = loadSeaModule();
31 if (sea === null) return false;
32 try {
33 return sea.isSea();
34 } catch {
35 return false;
36 }
37}
38
39// Path heuristic markers (compared in lowercase; both forward and backward slashes accepted).
40const PNPM_PATH_SEGMENT = 'pnpm/global/';

Callers

nothing calls this directly

Calls 2

loadSeaModuleFunction · 0.70
isSeaMethod · 0.65

Tested by

no test coverage detected