MCPcopy Index your code
hub / github.com/NativeScript/SimDeck / saveEntries

Function saveEntries

scripts/codex-worktree-cache.mjs:75–87  ·  view source on GitHub ↗
(entries)

Source from the content-addressed store, hash-verified

73}
74
75function saveEntries(entries) {
76 mkdirSync(CACHE_ROOT, { recursive: true });
77 for (const entry of entries) {
78 const source = join(ROOT, entry.destination);
79 if (!existsAndHasContent(source)) {
80 log(`skip ${entry.label}; ${entry.destination} is missing`);
81 continue;
82 }
83
84 copyIntoPlace(source, entry.cachePath, { replace: true });
85 log(`saved ${entry.label}`);
86 }
87}
88
89function printStatus(entries) {
90 console.log(`Cache root: ${CACHE_ROOT}`);

Callers 1

Calls 3

logFunction · 0.85
copyIntoPlaceFunction · 0.85
existsAndHasContentFunction · 0.70

Tested by

no test coverage detected