project-cypher 0.9.0 → 0.10.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/bin/cypher.js +2 -0
- package/package.json +1 -1
package/bin/cypher.js
CHANGED
|
@@ -170,6 +170,8 @@ const cmds = {
|
|
|
170
170
|
if (m.type === 'revoked') { runs.forEach(r => r.kill('SIGINT')); dropToken('Disconnected from the app. Run cypher init to link again.'); process.exit(0); }
|
|
171
171
|
const proj = m.projectId === 'root' ? { id: 'root', path: ROOT_DIR, root: true } : readRegistry().find(p => p.id === m.projectId); const ctx = { reqId: m.reqId, projectId: m.projectId };
|
|
172
172
|
if (m.type === 'stop') return runs.get(m.projectId)?.kill('SIGINT');
|
|
173
|
+
if (m.type === 'rmproject') { if (m.projectId !== 'root') writeRegistry(readRegistry().filter(x => x.id !== m.projectId)); return; }
|
|
174
|
+
if (m.type === 'reset') { const k = load(); if (k.sessions) { delete k.sessions[m.projectId]; save(k); } return; }
|
|
173
175
|
if (m.type !== 'prompt') return;
|
|
174
176
|
if (!proj) return tx({ ...ctx, type: 'error', message: 'unknown project' });
|
|
175
177
|
if (runs.has(proj.id)) return tx({ ...ctx, type: 'error', message: 'Claude is still working on this project.' });
|