MCPcopy Create free account
hub / github.com/SethGammon/Citadel / withTempProject

Function withTempProject

scripts/test-next-action.js:23–30  ·  view source on GitHub ↗
(run)

Source from the content-addressed store, hash-verified

21}
22
23function withTempProject(run) {
24 const dir = fs.mkdtempSync(path.join(os.tmpdir(), 'citadel-next-action-'));
25 try {
26 return run(dir);
27 } finally {
28 fs.rmSync(dir, { recursive: true, force: true });
29 }
30}
31
32assert.equal(localRepairFor({ command: '/learn --doc-sync' }).args[0].endsWith(path.join('hooks_src', 'doc-sync.js')), true);
33assert.equal(localRepairFor({ command: '/merge-review' }), null);

Callers 1

Calls 1

runFunction · 0.70

Tested by

no test coverage detected