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

Function ensureEntryFile

apps/kimi-code/src/native/native-assets.ts:208–216  ·  view source on GitHub ↗
(cacheRoot: string)

Source from the content-addressed store, hash-verified

206}
207
208function ensureEntryFile(cacheRoot: string): void {
209 const entryPath = join(cacheRoot, 'node_modules', '.kimi-native-entry.cjs');
210 ensureFile(
211 entryPath,
212 Buffer.from('module.exports = require;\n'),
213 sha256('module.exports = require;\n'),
214 0o644,
215 );
216}
217
218export function ensureNativeAssetTree(options: NativeAssetOptions = {}): string | null {
219 const source = options.source ?? getSeaAssetSource();

Callers 1

ensureNativeAssetTreeFunction · 0.85

Calls 2

ensureFileFunction · 0.70
sha256Function · 0.70

Tested by

no test coverage detected