MCPcopy Create free account
hub / github.com/dailydotdev/apps / install

Function install

packages/world-cli/src/dev.js:184–205  ·  view source on GitHub ↗
(file, target, report)

Source from the content-addressed store, hash-verified

182 };
183
184 const install = (file, target, report) => {
185 const frame = frameFor(report, target);
186 const key = keyOf(target);
187 const previous = builders.get(key);
188 if (report.ok) removedTargets.delete(key);
189 const status = withoutPayload(frame);
190 builders.set(key, {
191 file,
192 target,
193 status,
194 good: report.ok ? frame : previous?.good,
195 });
196 printReport(report, { json: false, file });
197
198 return {
199 upsert:
200 report.ok && frame.payloadHash !== previous?.good?.payloadHash
201 ? frame
202 : null,
203 report: status,
204 };
205 };
206
207 const rebuildFile = async (file, why) => {
208 if (!(await exists(file))) {

Callers 1

rebuildFileFunction · 0.85

Calls 5

printReportFunction · 0.90
frameForFunction · 0.85
withoutPayloadFunction · 0.85
getMethod · 0.80
keyOfFunction · 0.70

Tested by

no test coverage detected