otacon 0.1.1 → 0.1.2
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/README.md +101 -64
- package/dist/cli/browser.js +55 -0
- package/dist/cli/browser.js.map +1 -0
- package/dist/cli/commands/clean.js +3 -2
- package/dist/cli/commands/clean.js.map +1 -1
- package/dist/cli/commands/config.js +62 -0
- package/dist/cli/commands/config.js.map +1 -0
- package/dist/cli/commands/doctor.js +41 -21
- package/dist/cli/commands/doctor.js.map +1 -1
- package/dist/cli/commands/install.js +53 -30
- package/dist/cli/commands/install.js.map +1 -1
- package/dist/cli/commands/open.js +14 -14
- package/dist/cli/commands/open.js.map +1 -1
- package/dist/cli/commands/start.js +1 -22
- package/dist/cli/commands/start.js.map +1 -1
- package/dist/cli/install/assets.js +35 -43
- package/dist/cli/install/assets.js.map +1 -1
- package/dist/cli/install/locations.js +15 -25
- package/dist/cli/install/locations.js.map +1 -1
- package/dist/cli/main.js +6 -1
- package/dist/cli/main.js.map +1 -1
- package/dist/daemon/app.js +281 -54
- package/dist/daemon/app.js.map +1 -1
- package/dist/daemon/approve.js +49 -11
- package/dist/daemon/approve.js.map +1 -1
- package/dist/daemon/store.js +39 -2
- package/dist/daemon/store.js.map +1 -1
- package/dist/daemon/threads.js +11 -0
- package/dist/daemon/threads.js.map +1 -1
- package/dist/daemon/ui.js +3 -0
- package/dist/daemon/ui.js.map +1 -1
- package/dist/shared/config.js +290 -45
- package/dist/shared/config.js.map +1 -1
- package/dist/shared/paths.js +33 -5
- package/dist/shared/paths.js.map +1 -1
- package/dist/shared/types.js +6 -2
- package/dist/shared/types.js.map +1 -1
- package/dist/shared/version.js +1 -1
- package/dist/ui/assets/{arc-HhPfdCPZ.js → arc-KT3ZnaMp.js} +1 -1
- package/dist/ui/assets/architecture-7EHR7CIX-Cw3I1lil.js +1 -0
- package/dist/ui/assets/{architectureDiagram-3BPJPVTR-D2PIxGOb.js → architectureDiagram-3BPJPVTR-DLu0UM7N.js} +1 -1
- package/dist/ui/assets/{blockDiagram-GPEHLZMM-DQ3Dn17h.js → blockDiagram-GPEHLZMM-B8wApEWC.js} +1 -1
- package/dist/ui/assets/{c4Diagram-AAUBKEIU-DxITrQgS.js → c4Diagram-AAUBKEIU-BNS5gmQS.js} +1 -1
- package/dist/ui/assets/channel-CkOta24Z.js +1 -0
- package/dist/ui/assets/{chunk-2J33WTMH-Du1JoPx5.js → chunk-2J33WTMH-CTY2etwY.js} +1 -1
- package/dist/ui/assets/{chunk-3OPIFGDE-Dn7x2Yqf.js → chunk-3OPIFGDE-DZM4Sz84.js} +1 -1
- package/dist/ui/assets/{chunk-4BX2VUAB-DVnrE-4n.js → chunk-4BX2VUAB-sGwrrXIO.js} +1 -1
- package/dist/ui/assets/{chunk-55IACEB6-BAhFAimA.js → chunk-55IACEB6-CGlNp76o.js} +1 -1
- package/dist/ui/assets/{chunk-5ZQYHXKU-0hEZptem.js → chunk-5ZQYHXKU-5zebJ3jW.js} +1 -1
- package/dist/ui/assets/{chunk-727SXJPM-C1FN_cI3.js → chunk-727SXJPM-DelmUpvy.js} +1 -1
- package/dist/ui/assets/{chunk-AQP2D5EJ-A656OBd4.js → chunk-AQP2D5EJ-DMVzBf3M.js} +1 -1
- package/dist/ui/assets/{chunk-BSJP7CBP-D8oMbjm8.js → chunk-BSJP7CBP-CZHrcpSu.js} +1 -1
- package/dist/ui/assets/{chunk-CSCIHK7Q-DjIL8GLi.js → chunk-CSCIHK7Q-C1efTp0O.js} +1 -1
- package/dist/ui/assets/{chunk-FMBD7UC4-Otblfqvz.js → chunk-FMBD7UC4-B6axGwgn.js} +1 -1
- package/dist/ui/assets/{chunk-KSCS5N6A-BOjTvm3H.js → chunk-KSCS5N6A-DSaxbrm0.js} +1 -1
- package/dist/ui/assets/{chunk-L5ZTLDWV-CaTLaw6L.js → chunk-L5ZTLDWV-D9ZKdVGx.js} +1 -1
- package/dist/ui/assets/{chunk-LZXEDZCA-Dq5p7qrD.js → chunk-LZXEDZCA-DI5_1s00.js} +2 -2
- package/dist/ui/assets/{chunk-ND2GUHAM-jZ_NNnWi.js → chunk-ND2GUHAM-DQQ4RVLE.js} +1 -1
- package/dist/ui/assets/{chunk-NZK2D7GU-U_7l_sCh.js → chunk-NZK2D7GU-9zJJaDpb.js} +1 -1
- package/dist/ui/assets/{chunk-O5CBEL6O-MewqqNB7.js → chunk-O5CBEL6O-DUOshAt2.js} +1 -1
- package/dist/ui/assets/chunk-QZHKN3VN-DqRxzBM_.js +1 -0
- package/dist/ui/assets/chunk-WU5MYG2G-B1Mk3aBp.js +1 -0
- package/dist/ui/assets/{chunk-XPW4576I-D5ArxNEF.js → chunk-XPW4576I-DQVL_GAl.js} +1 -1
- package/dist/ui/assets/classDiagram-4FO5ZUOK-BH-5P4jH.js +1 -0
- package/dist/ui/assets/classDiagram-v2-Q7XG4LA2-BH-5P4jH.js +1 -0
- package/dist/ui/assets/{cose-bilkent-S5V4N54A-PFXzf7WV.js → cose-bilkent-S5V4N54A-C7m3VlSW.js} +1 -1
- package/dist/ui/assets/{dagre-BM42HDAG-xrCfjZuZ.js → dagre-BM42HDAG-CoU_T6EY.js} +1 -1
- package/dist/ui/assets/{diagram-2AECGRRQ-BFf-cyKY.js → diagram-2AECGRRQ-C_R7oNKE.js} +1 -1
- package/dist/ui/assets/{diagram-5GNKFQAL-kNPV4NfV.js → diagram-5GNKFQAL-UhE2W3Yi.js} +1 -1
- package/dist/ui/assets/{diagram-KO2AKTUF-ByC1IUwG.js → diagram-KO2AKTUF-D4KZCRld.js} +1 -1
- package/dist/ui/assets/{diagram-LMA3HP47-DZIJMPK0.js → diagram-LMA3HP47-CsOe8-S6.js} +1 -1
- package/dist/ui/assets/{diagram-OG6HWLK6-CSDED9A-.js → diagram-OG6HWLK6-Bkbs2V54.js} +1 -1
- package/dist/ui/assets/{dist-YwjsDswi.js → dist-BcowSnUl.js} +1 -1
- package/dist/ui/assets/{erDiagram-TEJ5UH35-yuzvjE6J.js → erDiagram-TEJ5UH35-DJXsykZz.js} +1 -1
- package/dist/ui/assets/eventmodeling-FCH6USID-DSDI1f5T.js +1 -0
- package/dist/ui/assets/{flowDiagram-I6XJVG4X-ApPtVyYM.js → flowDiagram-I6XJVG4X-Chguj9Xz.js} +1 -1
- package/dist/ui/assets/{ganttDiagram-6RSMTGT7-BeMLXtAr.js → ganttDiagram-6RSMTGT7-DXdpFesp.js} +1 -1
- package/dist/ui/assets/{gitGraph-WXDBUCRP-JmTTBa7j.js → gitGraph-WXDBUCRP-Doq1CcxB.js} +1 -1
- package/dist/ui/assets/{gitGraphDiagram-PVQCEYII-Cjjnjs71.js → gitGraphDiagram-PVQCEYII-uxGwHEPv.js} +1 -1
- package/dist/ui/assets/index-BsTJ9Ul_.css +1 -0
- package/dist/ui/assets/index-D-TSanrw.js +11 -0
- package/dist/ui/assets/{info-J43DQDTF-8vZ3gome.js → info-J43DQDTF-CgWT_d3M.js} +1 -1
- package/dist/ui/assets/{infoDiagram-5YYISTIA-CnMk1cA-.js → infoDiagram-5YYISTIA-B3oDA2Ct.js} +1 -1
- package/dist/ui/assets/{ishikawaDiagram-YF4QCWOH-Bl8z6huD.js → ishikawaDiagram-YF4QCWOH-C6l0lvC3.js} +1 -1
- package/dist/ui/assets/{journeyDiagram-JHISSGLW-DYIVfMpS.js → journeyDiagram-JHISSGLW-COf53NwC.js} +1 -1
- package/dist/ui/assets/{kanban-definition-UN3LZRKU-BnR0ZzOz.js → kanban-definition-UN3LZRKU-DaOPRBld.js} +1 -1
- package/dist/ui/assets/{line-DcBdQit6.js → line-new3jLu3.js} +1 -1
- package/dist/ui/assets/{linear-HKjRHFAO.js → linear-yA22knFB.js} +1 -1
- package/dist/ui/assets/{mermaid-parser.core-DkYXrPlA.js → mermaid-parser.core-D8JVCOKU.js} +2 -2
- package/dist/ui/assets/{mermaid.core-BmkfCI3b.js → mermaid.core-BCrPyVBK.js} +3 -3
- package/dist/ui/assets/{mindmap-definition-RKZ34NQL-sIAd4nDi.js → mindmap-definition-RKZ34NQL-CVcJTWsW.js} +1 -1
- package/dist/ui/assets/{packet-YPE3B663-BxbxcfXN.js → packet-YPE3B663-DlSwpK-G.js} +1 -1
- package/dist/ui/assets/{pie-LRSECV5Y-BJxazjNs.js → pie-LRSECV5Y-CyMpbo4C.js} +1 -1
- package/dist/ui/assets/{pieDiagram-4H26LBE5-BiOhc9GR.js → pieDiagram-4H26LBE5-Dy7day5R.js} +1 -1
- package/dist/ui/assets/{plan-view-CH6NzUDb.js → plan-view-CE2ha0qY.js} +3 -3
- package/dist/ui/assets/{quadrantDiagram-W4KKPZXB-CVyHbWgo.js → quadrantDiagram-W4KKPZXB-CVjVgbaQ.js} +1 -1
- package/dist/ui/assets/{radar-GUYGQ44K-D9ohbnbV.js → radar-GUYGQ44K-DLPfv0jT.js} +1 -1
- package/dist/ui/assets/{requirementDiagram-4Y6WPE33-Ba24_hqc.js → requirementDiagram-4Y6WPE33-y_0KOdN8.js} +1 -1
- package/dist/ui/assets/{sankeyDiagram-5OEKKPKP-CxD4wiPL.js → sankeyDiagram-5OEKKPKP-8T3b7meL.js} +1 -1
- package/dist/ui/assets/{sequenceDiagram-3UESZ5HK-7qA7lD61.js → sequenceDiagram-3UESZ5HK-Cn8DZiEr.js} +1 -1
- package/dist/ui/assets/{src-IM8AE8MK.js → src-BieOuieI.js} +1 -1
- package/dist/ui/assets/{stateDiagram-AJRCARHV-DNElRCuH.js → stateDiagram-AJRCARHV-nPEVGd3E.js} +1 -1
- package/dist/ui/assets/stateDiagram-v2-BHNVJYJU-CKrff-KJ.js +1 -0
- package/dist/ui/assets/{timeline-definition-PNZ67QCA-ChYC4Grd.js → timeline-definition-PNZ67QCA-Dj_qK0VJ.js} +1 -1
- package/dist/ui/assets/{treeView-BLDUP644-Il0KnMi_.js → treeView-BLDUP644-G5Bsebqu.js} +1 -1
- package/dist/ui/assets/{treemap-LRROVOQU-CIiKcdRo.js → treemap-LRROVOQU-anUEJzTb.js} +1 -1
- package/dist/ui/assets/{vennDiagram-CIIHVFJN-Ulhkum9i.js → vennDiagram-CIIHVFJN-D71ne3dS.js} +1 -1
- package/dist/ui/assets/{wardley-L42UT6IY-BNd4ljz7.js → wardley-L42UT6IY-DrJilmE_.js} +1 -1
- package/dist/ui/assets/{wardleyDiagram-YWT4CUSO-BicXxh84.js → wardleyDiagram-YWT4CUSO-B66G4ayp.js} +1 -1
- package/dist/ui/assets/{xychartDiagram-2RQKCTM6-Duf-m_th.js → xychartDiagram-2RQKCTM6-CReSRxNG.js} +1 -1
- package/dist/ui/index.html +2 -2
- package/package.json +1 -1
- package/dist/ui/assets/architecture-7EHR7CIX-BPLblcyi.js +0 -1
- package/dist/ui/assets/channel-ipcU8ZNI.js +0 -1
- package/dist/ui/assets/chunk-QZHKN3VN-DzGPH44B.js +0 -1
- package/dist/ui/assets/chunk-WU5MYG2G-DyEIVjoo.js +0 -1
- package/dist/ui/assets/classDiagram-4FO5ZUOK-Byg2Hl9D.js +0 -1
- package/dist/ui/assets/classDiagram-v2-Q7XG4LA2-Byg2Hl9D.js +0 -1
- package/dist/ui/assets/eventmodeling-FCH6USID-CZR4eNG-.js +0 -1
- package/dist/ui/assets/index-BFQVRcSI.js +0 -11
- package/dist/ui/assets/index-Bj_kTrwP.css +0 -1
- package/dist/ui/assets/stateDiagram-v2-BHNVJYJU-D6qTYpY3.js +0 -1
|
@@ -1,11 +1,14 @@
|
|
|
1
|
-
// otacon open [--session id]
|
|
2
|
-
// convenience).
|
|
3
|
-
//
|
|
4
|
-
//
|
|
5
|
-
//
|
|
1
|
+
// otacon open [--session id]: launch the review URL in the browser (DESIGN.md
|
|
2
|
+
// §6, human convenience). It runs on the human's machine and the verb means "show
|
|
3
|
+
// me the page", so it spawns the browser; OTACON_NO_BROWSER prints the URL as JSON
|
|
4
|
+
// instead, for headless hosts and URL-parsing agents (DECISIONS.md "open and
|
|
5
|
+
// config launch the browser"). With no resolvable session the index URL is the
|
|
6
|
+
// answer, not an error; reading is never the wrong screen, and the never-guess
|
|
7
|
+
// rule guards writes, not looks.
|
|
6
8
|
import { parseArgs } from "node:util";
|
|
9
|
+
import { openOrPrint } from "../browser.js";
|
|
7
10
|
import { baseUrl, ensureDaemon } from "../client.js";
|
|
8
|
-
import { CliError, notice
|
|
11
|
+
import { CliError, notice } from "../output.js";
|
|
9
12
|
import { listSessions, realpathOr, resolveSession } from "../session.js";
|
|
10
13
|
export async function openCommand(argv) {
|
|
11
14
|
const { values } = parseArgs({
|
|
@@ -16,12 +19,8 @@ export async function openCommand(argv) {
|
|
|
16
19
|
const sessions = await listSessions();
|
|
17
20
|
try {
|
|
18
21
|
const session = resolveSession(sessions, values.session, realpathOr(process.cwd()));
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
session: session.id,
|
|
22
|
-
title: session.title,
|
|
23
|
-
url: `${baseUrl()}/s/${session.id}`,
|
|
24
|
-
});
|
|
22
|
+
const url = `${baseUrl()}/s/${session.id}`;
|
|
23
|
+
openOrPrint(url, { ok: true, session: session.id, title: session.title, url });
|
|
25
24
|
}
|
|
26
25
|
catch (error) {
|
|
27
26
|
// An explicit --session that fails to resolve is a real refusal; implicit
|
|
@@ -29,8 +28,9 @@ export async function openCommand(argv) {
|
|
|
29
28
|
// the index, which lists everything.
|
|
30
29
|
if (!(error instanceof CliError) || values.session !== undefined)
|
|
31
30
|
throw error;
|
|
32
|
-
notice(`${error.message}
|
|
33
|
-
|
|
31
|
+
notice(`${error.message}; using the index`);
|
|
32
|
+
const url = `${baseUrl()}/`;
|
|
33
|
+
openOrPrint(url, { ok: true, url });
|
|
34
34
|
}
|
|
35
35
|
return 0;
|
|
36
36
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"open.js","sourceRoot":"","sources":["../../../src/cli/commands/open.ts"],"names":[],"mappings":"AAAA,
|
|
1
|
+
{"version":3,"file":"open.js","sourceRoot":"","sources":["../../../src/cli/commands/open.ts"],"names":[],"mappings":"AAAA,8EAA8E;AAC9E,kFAAkF;AAClF,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C9E,MAAM,CAAC,GAAG,KAAK,CAAC,OAAO,mBAAmB,CAAC,CAAC;QAC5C,MAAM,GAAG,GAAG,GAAG,OAAO,EAAE,GAAG,CAAC;QAC5B,WAAW,CAAC,GAAG,EAAE,EAAE,EAAE,EAAE,IAAI,EAAE,GAAG,EAAE,CAAC,CAAC;IACtC,CAAC;IACD,OAAO,CAAC,CAAC;AACX,CAAC"}
|
|
@@ -1,9 +1,6 @@
|
|
|
1
1
|
// otacon start --title <t> [--quick] — mint and register a session (DESIGN.md
|
|
2
|
-
// §6, §16): POST /api/sessions,
|
|
3
|
-
// missing (with a notice), print the session id and review URL. No local
|
|
2
|
+
// §6, §16): POST /api/sessions, print the session id and review URL. No local
|
|
4
3
|
// session pointer — the daemon registry is the single source of truth (§7).
|
|
5
|
-
import { appendFileSync, existsSync, readFileSync } from "node:fs";
|
|
6
|
-
import { join } from "node:path";
|
|
7
4
|
import { parseArgs } from "node:util";
|
|
8
5
|
import { api, baseUrl, ensureDaemon } from "../client.js";
|
|
9
6
|
import { fail, notice, printJson, usageError } from "../output.js";
|
|
@@ -34,8 +31,6 @@ export async function startCommand(argv) {
|
|
|
34
31
|
fail("E_INTERNAL", `session create failed: ${JSON.stringify(created.body)}`, undefined, 2);
|
|
35
32
|
}
|
|
36
33
|
const session = created.body;
|
|
37
|
-
if (gitRoot !== undefined)
|
|
38
|
-
ensureGitignore(gitRoot);
|
|
39
34
|
printJson({
|
|
40
35
|
ok: true,
|
|
41
36
|
session: session.id,
|
|
@@ -47,20 +42,4 @@ export async function startCommand(argv) {
|
|
|
47
42
|
});
|
|
48
43
|
return 0;
|
|
49
44
|
}
|
|
50
|
-
/** First start in a repo appends .otacon/ to .gitignore, with a notice (DESIGN.md §16). */
|
|
51
|
-
export function ensureGitignore(repo) {
|
|
52
|
-
const path = join(repo, ".gitignore");
|
|
53
|
-
const existing = existsSync(path) ? readFileSync(path, "utf8") : "";
|
|
54
|
-
const covered = existing
|
|
55
|
-
.split("\n")
|
|
56
|
-
.some((line) => /^\/?\.otacon\/?$/.test(line.trim()));
|
|
57
|
-
if (covered)
|
|
58
|
-
return;
|
|
59
|
-
// Match the file's own line endings — appending LF to a CRLF file would
|
|
60
|
-
// leave it with mixed endings.
|
|
61
|
-
const eol = existing.includes("\r\n") ? "\r\n" : "\n";
|
|
62
|
-
const separator = existing === "" || existing.endsWith("\n") ? "" : eol;
|
|
63
|
-
appendFileSync(path, `${separator}.otacon/${eol}`);
|
|
64
|
-
notice(`appended .otacon/ to ${path} (working state stays out of git, DESIGN.md §12)`);
|
|
65
|
-
}
|
|
66
45
|
//# sourceMappingURL=start.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"start.js","sourceRoot":"","sources":["../../../src/cli/commands/start.ts"],"names":[],"mappings":"AAAA,8EAA8E;AAC9E,
|
|
1
|
+
{"version":3,"file":"start.js","sourceRoot":"","sources":["../../../src/cli/commands/start.ts"],"names":[],"mappings":"AAAA,8EAA8E;AAC9E,8EAA8E;AAC9E,4EAA4E;AAE5E,OAAO,EAAE,SAAS,EAAE,MAAM,WAAW,CAAC;AAEtC,OAAO,EAAE,GAAG,EAAE,OAAO,EAAE,YAAY,EAAE,MAAM,cAAc,CAAC;AAC1D,OAAO,EAAE,IAAI,EAAE,MAAM,EAAE,SAAS,EAAE,UAAU,EAAE,MAAM,cAAc,CAAC;AACnE,OAAO,EAAE,aAAa,EAAE,YAAY,EAAE,UAAU,EAAE,MAAM,eAAe,CAAC;AAExE,MAAM,CAAC,KAAK,UAAU,YAAY,CAAC,IAAc;IAC/C,MAAM,EAAE,MAAM,EAAE,GAAG,SAAS,CAAC;QAC3B,IAAI,EAAE,IAAI;QACV,OAAO,EAAE,EAAE,KAAK,EAAE,EAAE,IAAI,EAAE,QAAQ,EAAE,EAAE,KAAK,EAAE,EAAE,IAAI,EAAE,SAAS,EAAE,OAAO,EAAE,KAAK,EAAE,EAAE;KACnF,CAAC,CAAC;IACH,IAAI,MAAM,CAAC,KAAK,K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C,EAAE,EAAE;KACpC,CAAC,CAAC;IACH,OAAO,CAAC,CAAC;AACX,CAAC"}
|
|
@@ -1,14 +1,12 @@
|
|
|
1
1
|
// The wrapper content `otacon install` writes (DESIGN.md §16) — this is the
|
|
2
2
|
// product-critical text that teaches an agent the whole protocol: the §6 full
|
|
3
3
|
// loop, §8 grill discipline, and §13 "never end your turn". One protocol card,
|
|
4
|
-
// three destinations
|
|
5
|
-
//
|
|
6
|
-
//
|
|
7
|
-
//
|
|
4
|
+
// three destinations — Claude Code, Codex, and OpenCode each get it as a
|
|
5
|
+
// SKILL.md in their own skills dir. Plus the Stop hook shell script (§13).
|
|
6
|
+
// Wrappers are managed files: reinstall overwrites them wholesale (DECISIONS.md
|
|
7
|
+
// "Wrappers are managed files").
|
|
8
8
|
/** Present in every wrapper this tool owns; doctor greps for it. */
|
|
9
9
|
export const MANAGED_MARKER = 'managed by `otacon install`';
|
|
10
|
-
export const CODEX_BEGIN = '<!-- BEGIN OTACON — managed by `otacon install`; content inside these markers is overwritten on reinstall -->';
|
|
11
|
-
export const CODEX_END = '<!-- END OTACON -->';
|
|
12
10
|
/**
|
|
13
11
|
* The protocol card — §6 full loop (start-first) + §8 grill discipline + §13
|
|
14
12
|
* failure habits — parametrized by the command prefix so one source feeds both
|
|
@@ -27,7 +25,7 @@ machine-readable error you can fix (read the JSON); exit 2 = you invoked it wron
|
|
|
27
25
|
|
|
28
26
|
1. \`${cmd} start --title <kebab-title>\` **first, before you research** — it mints
|
|
29
27
|
the session and prints the review URL. Tell the user to open it (\`${cmd} open\`
|
|
30
|
-
|
|
28
|
+
launches it in their browser) so they can watch the whole thing from the first second.
|
|
31
29
|
\`--quick\` skips the interview — only when the user explicitly asks.
|
|
32
30
|
2. **Research the codebase**, narrating as you go with
|
|
33
31
|
\`${cmd} progress "<what you're doing>"\` — call it whenever you start a chunk of
|
|
@@ -59,18 +57,23 @@ machine-readable error you can fix (read the JSON); exit 2 = you invoked it wron
|
|
|
59
57
|
- \`comments\` → revise plan.md; write \`resolutions.json\` as
|
|
60
58
|
\`{"changelog":"what changed","threads":{"t1":"how you resolved it"}}\` with
|
|
61
59
|
one reply per comment thread; \`${cmd} submit --resolutions resolutions.json\`
|
|
62
|
-
(loop on lint errors); park again.
|
|
60
|
+
(loop on lint errors); park again. A \`comments\` batch with \`"final":true\` is
|
|
61
|
+
the reviewer's **comment & approve**: resolve every thread the usual way, but
|
|
62
|
+
your next clean submit **finalizes** — you'll get \`approved\` (which may carry
|
|
63
|
+
\`implement:true\`), not another review round. So fold them all in, submit, then
|
|
64
|
+
park and handle the \`approved\` that follows (do NOT expect more comments).
|
|
63
65
|
- \`question\` → \`${cmd} answer <q-id> --body "..."\` (or \`--file\`); park again. A
|
|
64
66
|
\`question\` may carry \`replyTo\` (a follow-up on an earlier question) — skim that
|
|
65
67
|
thread's prior turns for context, but still answer the new \`q<n>\`.
|
|
66
68
|
- \`answer\` → use it and continue; park again whenever you are waiting.
|
|
67
69
|
- \`timeout\` → park again immediately. A timeout is NEVER completion.
|
|
68
|
-
- \`approved\` →
|
|
69
|
-
\`
|
|
70
|
-
**with \`implement:true\`** →
|
|
71
|
-
(below) — do NOT stop; the
|
|
70
|
+
- \`approved\` → the plan is saved at \`path\`. Plain \`approved\` (Save, no
|
|
71
|
+
\`implement\`) → print a one-line summary naming where it was saved (\`path\`),
|
|
72
|
+
then STOP. \`approved\` **with \`implement:true\`** → read the plan at \`path\` to
|
|
73
|
+
guide the build and enter the **Implement loop** (below) — do NOT stop; the
|
|
74
|
+
session is now \`implementing\`.
|
|
72
75
|
- \`deleted\` → the user deleted this session in the review UI. It is over:
|
|
73
|
-
STOP. There is no approved plan
|
|
76
|
+
STOP. There is no approved plan.
|
|
74
77
|
6. **Never end your turn while the session is open.** Nothing to do = park in
|
|
75
78
|
\`${cmd} wait\` again. Confused, crashed, or compacted? \`${cmd} status\` returns
|
|
76
79
|
the open session, revision, and pending events — resume the loop from it.
|
|
@@ -80,7 +83,7 @@ machine-readable error you can fix (read the JSON); exit 2 = you invoked it wron
|
|
|
80
83
|
- \`${cmd} start --title <t> [--quick]\` · \`${cmd} progress "<note>"\` ·
|
|
81
84
|
\`${cmd} ask ...\` · \`${cmd} wait --timeout 540\` · \`${cmd} submit [--resolutions f]\` ·
|
|
82
85
|
\`${cmd} answer <q> --body "..."\` · \`${cmd} implement-done [--pr <url>] [--failed]\` ·
|
|
83
|
-
\`${cmd} status\` · \`${cmd} open\`
|
|
86
|
+
\`${cmd} status\` · \`${cmd} open\` · \`${cmd} config [get <key>]\`
|
|
84
87
|
|
|
85
88
|
## Implement loop (on \`approved\` with \`implement:true\`)
|
|
86
89
|
|
|
@@ -88,10 +91,14 @@ You are the **orchestrator**: you only coordinate and narrate
|
|
|
88
91
|
(\`${cmd} progress\` at each checkpoint) — every phase's real work runs in a fresh
|
|
89
92
|
native subagent (Task tool) so your own context stays lean.
|
|
90
93
|
|
|
91
|
-
1. **Setup.**
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
94
|
+
1. **Setup.** On Implement the plan lives only in the home archive at the event
|
|
95
|
+
\`path\` (read the phases from there). Branch off the repo's current default branch
|
|
96
|
+
HEAD: create the
|
|
97
|
+
worktree under the configured \`worktree.dir\`
|
|
98
|
+
(\`${cmd} config get worktree.dir\` — default \`~/.otacon/worktrees\`, outside the repo):
|
|
99
|
+
\`git worktree add <worktree.dir>/<slug> -b otacon/impl-<slug>\` (off the default
|
|
100
|
+
branch). \`${cmd} progress\` each checkpoint throughout.
|
|
101
|
+
2. **Per phase, in order** (read the phases from the home plan at the event \`path\`):
|
|
95
102
|
- \`${cmd} progress "phase N — implementing"\`; spawn an **implement+test**
|
|
96
103
|
subagent (Task tool) scoped to that phase's Goal/Files/Verification — it
|
|
97
104
|
implements and runs the phase Verification plus the repo gates.
|
|
@@ -102,14 +109,10 @@ native subagent (Task tool) so your own context stays lean.
|
|
|
102
109
|
review still flags, or a subagent is stuck) → on the FIRST blocker,
|
|
103
110
|
\`${cmd} ask\` with options \`retry|skip|abort|guidance\`, park in \`${cmd} wait\`,
|
|
104
111
|
and act on the answer. No auto-retry.
|
|
105
|
-
3. **Finish.** On success,
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
the plan summary + the per-phase log; fall back to the local branch + path when
|
|
110
|
-
there is no remote), then \`${cmd} implement-done --pr <url>\`. On abort, skip the
|
|
111
|
-
archive move (leave the plan in \`docs/plans/\` so it stays active) and run
|
|
112
|
-
\`${cmd} implement-done --failed\`.
|
|
112
|
+
3. **Finish.** On success, open a PR against the default branch with \`gh pr create\`
|
|
113
|
+
(PR body = the plan summary + the per-phase log; fall back to the local branch +
|
|
114
|
+
path when there is no remote), then \`${cmd} implement-done --pr <url>\`. On abort,
|
|
115
|
+
run \`${cmd} implement-done --failed\`.
|
|
113
116
|
|
|
114
117
|
While \`implementing\` the Stop hook still keeps you on the line — never end the turn
|
|
115
118
|
until \`implement-done\`.
|
|
@@ -184,11 +187,11 @@ than a sentence — never as decoration.
|
|
|
184
187
|
while the session runs.
|
|
185
188
|
`;
|
|
186
189
|
}
|
|
187
|
-
/**
|
|
190
|
+
/** The SKILL.md every agent's skills dir gets (Claude, Codex, OpenCode — same format). */
|
|
188
191
|
export function skillMd() {
|
|
189
192
|
return `---
|
|
190
193
|
name: otacon
|
|
191
|
-
description: Plan a feature through an otacon review session — grill interview, schema'd plan, phone review with anchored comments, approved
|
|
194
|
+
description: Plan a feature through an otacon review session — grill interview, schema'd plan, phone review with anchored comments, approved plan saved to a home archive (and your project on Save). Use when the user asks to plan something with otacon, types /otacon, or wants a reviewed implementation plan before coding. Replaces native plan mode.
|
|
192
195
|
---
|
|
193
196
|
|
|
194
197
|
<!-- ${MANAGED_MARKER} — reinstall overwrites this file; the spec lives in otacon's DESIGN.md -->
|
|
@@ -197,18 +200,6 @@ description: Plan a feature through an otacon review session — grill interview
|
|
|
197
200
|
|
|
198
201
|
${protocolCard('otacon')}`;
|
|
199
202
|
}
|
|
200
|
-
/** The marker-delimited block upserted into ~/.codex/AGENTS.md. */
|
|
201
|
-
export function codexBlock() {
|
|
202
|
-
return `${CODEX_BEGIN}
|
|
203
|
-
|
|
204
|
-
# Otacon plan sessions
|
|
205
|
-
|
|
206
|
-
When the user asks you to plan a feature "with otacon" (or to run a plan
|
|
207
|
-
review), follow this protocol exactly.
|
|
208
|
-
|
|
209
|
-
${protocolCard('otacon')}
|
|
210
|
-
${CODEX_END}`;
|
|
211
|
-
}
|
|
212
203
|
/**
|
|
213
204
|
* THIS repo's dogfood wrapper — the committed \`.claude/skills/otacon/SKILL.md\`
|
|
214
205
|
* (DESIGN.md §16). It is the same protocol card as \`skillMd()\`, but with the
|
|
@@ -221,7 +212,7 @@ ${CODEX_END}`;
|
|
|
221
212
|
export function dogfoodSkillMd() {
|
|
222
213
|
return `---
|
|
223
214
|
name: otacon
|
|
224
|
-
description: Plan a feature for THIS repo through an otacon review session — grill interview, schema'd plan, browser/phone review with anchored comments, approved
|
|
215
|
+
description: Plan a feature for THIS repo through an otacon review session — grill interview, schema'd plan, browser/phone review with anchored comments, approved plan saved to a home archive (and your project on Save). Use when the user asks to plan something with otacon, types /otacon, or wants a reviewed implementation plan before coding. Replaces native plan mode. Dogfoods otacon on its own development.
|
|
225
216
|
---
|
|
226
217
|
|
|
227
218
|
<!-- Generated from src/cli/install/assets.ts (dogfoodSkillMd) — do NOT hand-edit;
|
|
@@ -234,8 +225,9 @@ This repo **is** otacon. You plan features for it by running otacon's own CLI fr
|
|
|
234
225
|
source via the \`./bin/otacon\` shim, so every command below exercises the code in
|
|
235
226
|
this checkout. That shim runs the CLI from \`src/\` via bun — no build needed; it
|
|
236
227
|
always reflects current source. The daemon auto-spawns from source on the first
|
|
237
|
-
command. Working state lives in
|
|
238
|
-
|
|
228
|
+
command. Working state lives in \`.otacon/\`; the approved plan is archived in the
|
|
229
|
+
home store (\`~/.otacon/sessions/<id>/\`) and, on Save, copied into the repo under
|
|
230
|
+
\`plans.dir\` (default \`.otacon/plans\`).
|
|
239
231
|
|
|
240
232
|
After editing **daemon** source (\`src/daemon/**\`) mid-session, restart the running
|
|
241
233
|
daemon so your change loads: \`./bin/otacon restart\` (the next command respawns it
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"assets.js","sourceRoot":"","sources":["../../../src/cli/install/assets.ts"],"names":[],"mappings":"AAAA,4EAA4E;AAC5E,8EAA8E;AAC9E,+EAA+E;AAC/E,
|
|
1
|
+
{"version":3,"file":"assets.js","sourceRoot":"","sources":["../../../src/cli/install/assets.ts"],"names":[],"mappings":"AAAA,4EAA4E;AAC5E,8EAA8E;AAC9E,+EAA+E;AAC/E,yEAAyE;AACzE,2EAA2E;AAC3E,gFAAgF;AAChF,iCAAiC;AAEjC,oEAAoE;AACpE,MAAM,CAAC,MAAM,cAAc,GAAG,6BAA6B,CAAC;AAE5D;;;;;;;GAOG;AACH,SAAS,YAAY,CAAC,GAAW;IAC/B,OAAO;qCAC4B,GAAG;;;;;;OAMjC,GAAG;wEAC8D,GAAG;;;;OAIpE,GAAG;;;;;;;;;;SAUD,GAAG;;;;;eAKG,GAAG;;;;8BAIY,GAAG;;;OAG1B,GAAG;;iCAEuB,GAAG;;;;uCAIG,GAAG;;;;;;wBAMlB,GAAG;;;;;;;;;;;;;OAapB,GAAG,qDAAqD,GAAG;;;;;MAK5D,GAAG,sCAAsC,GAAG;MAC5C,GAAG,kBAAkB,GAAG,6BAA6B,GAAG;MACxD,GAAG,kCAAkC,GAAG;MACxC,GAAG,iBAAiB,GAAG,eAAe,GAAG;;;;;KAK1C,GAAG;;;;;;;QAOA,GAAG;;gBAEK,GAAG;;SAEV,GAAG;;;;;;;;SAQH,GAAG,gEAAgE,GAAG;;;;2CAIpC,GAAG;WACnC,GAAG;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;wDAsE0C,GAAG;;;CAG1D,CAAC;AACF,CAAC;AAED,0FAA0F;AAC1F,MAAM,UAAU,OAAO;IACrB,OAAO;;;;;OAKF,cAAc;;;;EAInB,YAAY,CAAC,QAAQ,CAAC,EAAE,CAAC;AAC3B,CAAC;AAED;;;;;;;;GAQG;AACH,MAAM,UAAU,cAAc;IAC5B,OAAO;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EA8BP,YAAY,CAAC,cAAc,CAAC,EAAE,CAAC;AACjC,CAAC;AAED;;;;;;;;GAQG;AACH,MAAM,CAAC,MAAM,gBAAgB,GAAG;uBACT,cAAc;;;;;;;;;;;;;;;;;;;;;CAqBpC,CAAC"}
|
|
@@ -5,8 +5,9 @@
|
|
|
5
5
|
import { readFileSync } from "node:fs";
|
|
6
6
|
import { homedir } from "node:os";
|
|
7
7
|
import { join } from "node:path";
|
|
8
|
-
export function claudeSkillPath() {
|
|
9
|
-
|
|
8
|
+
export function claudeSkillPath(scope = { kind: "user" }) {
|
|
9
|
+
const base = scope.kind === "project" ? scope.root : homedir();
|
|
10
|
+
return join(base, ".claude", "skills", "otacon", "SKILL.md");
|
|
10
11
|
}
|
|
11
12
|
/** The Stop hook script install writes; settings.json references it by this path. */
|
|
12
13
|
export function claudeHookScriptPath() {
|
|
@@ -15,30 +16,19 @@ export function claudeHookScriptPath() {
|
|
|
15
16
|
export function claudeSettingsPath() {
|
|
16
17
|
return join(homedir(), ".claude", "settings.json");
|
|
17
18
|
}
|
|
18
|
-
/** Codex's
|
|
19
|
-
export function
|
|
20
|
-
|
|
19
|
+
/** Codex's skills dir — user: $CODEX_HOME (default ~/.codex); project: <root>/.codex. */
|
|
20
|
+
export function codexSkillPath(scope = { kind: "user" }) {
|
|
21
|
+
const base = scope.kind === "project"
|
|
22
|
+
? join(scope.root, ".codex")
|
|
23
|
+
: (process.env.CODEX_HOME ?? join(homedir(), ".codex"));
|
|
24
|
+
return join(base, "skills", "otacon", "SKILL.md");
|
|
21
25
|
}
|
|
22
|
-
/** OpenCode's
|
|
23
|
-
export function opencodeSkillPath() {
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
* its own begin/end lines), or append it when no markers are present. User
|
|
29
|
-
* content outside the markers survives byte-for-byte; re-running with the same
|
|
30
|
-
* block is a fixpoint (the idempotent-reinstall contract).
|
|
31
|
-
*/
|
|
32
|
-
export function upsertMarkedBlock(existing, block, begin, end) {
|
|
33
|
-
const from = existing.indexOf(begin);
|
|
34
|
-
const to = existing.indexOf(end);
|
|
35
|
-
if (from !== -1 && to !== -1 && to > from) {
|
|
36
|
-
return existing.slice(0, from) + block + existing.slice(to + end.length);
|
|
37
|
-
}
|
|
38
|
-
if (existing.trim() === "")
|
|
39
|
-
return `${block}\n`;
|
|
40
|
-
const separator = existing.endsWith("\n") ? "\n" : "\n\n";
|
|
41
|
-
return `${existing}${separator}${block}\n`;
|
|
26
|
+
/** OpenCode's skills dir — user: $XDG_CONFIG_HOME/opencode (default ~/.config); project: <root>/.opencode. */
|
|
27
|
+
export function opencodeSkillPath(scope = { kind: "user" }) {
|
|
28
|
+
const base = scope.kind === "project"
|
|
29
|
+
? join(scope.root, ".opencode")
|
|
30
|
+
: join(process.env.XDG_CONFIG_HOME ?? join(homedir(), ".config"), "opencode");
|
|
31
|
+
return join(base, "skills", "otacon", "SKILL.md");
|
|
42
32
|
}
|
|
43
33
|
/**
|
|
44
34
|
* Whether ~/.claude/settings.json currently registers the otacon Stop hook
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"locations.js","sourceRoot":"","sources":["../../../src/cli/install/locations.ts"],"names":[],"mappings":"AAAA,uEAAuE;AACvE,yEAAyE;AACzE,4EAA4E;AAC5E,0CAA0C;AAE1C,OAAO,EAAE,YAAY,EAAE,MAAM,SAAS,CAAC;AACvC,OAAO,EAAE,OAAO,EAAE,MAAM,SAAS,CAAC;AAClC,OAAO,EAAE,IAAI,EAAE,MAAM,WAAW,CAAC;
|
|
1
|
+
{"version":3,"file":"locations.js","sourceRoot":"","sources":["../../../src/cli/install/locations.ts"],"names":[],"mappings":"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AI,IAAI,OAAO,GAAG,KAAK,QAAQ,IAAI,KAAK,CAAC,OAAO,CAAC,GAAG,CAAC;QAAE,OAAO,SAAS,CAAC;IACpF,MAAM,QAAQ,GAAG,GAA8B,CAAC;IAChD,MAAM,KAAK,GAAG,QAAQ,CAAC,KAAK,IAAI,EAAE,CAAC;IACnC,IAAI,KAAK,KAAK,IAAI,IAAI,OAAO,KAAK,KAAK,QAAQ,IAAI,KAAK,CAAC,OAAO,CAAC,KAAK,CAAC;QAAE,OAAO,SAAS,CAAC;IAC1F,MAAM,IAAI,GAAI,KAAiC,CAAC,IAAI,IAAI,EAAE,CAAC;IAC3D,IAAI,CAAC,KAAK,CAAC,OAAO,CAAC,IAAI,CAAC;QAAE,OAAO,SAAS,CAAC;IAC3C,IAAI,kBAAkB,CAAC,IAAI,EAAE,OAAO,CAAC;QAAE,OAAO,EAAE,QAAQ,EAAE,OAAO,EAAE,KAAK,EAAE,CAAC;IAC3E,MAAM,KAAK,GAAG,EAAE,OAAO,EAAE,EAAE,EAAE,KAAK,EAAE,CAAC,EAAE,IAAI,EAAE,SAAS,EAAE,OAAO,EAAE,CAAC,EAAE,CAAC;IACrE,OAAO;QACL,QAAQ,EAAE,EAAE,GAAG,QAAQ,EAAE,KAAK,EAAE,EAAE,GAAG,KAAK,EAAE,IAAI,EAAE,CAAC,GAAG,IAAI,EAAE,KAAK,CAAC,EAAE,EAAE;QACtE,OAAO,EAAE,IAAI;KACd,CAAC;AACJ,CAAC"}
|
package/dist/cli/main.js
CHANGED
|
@@ -5,6 +5,7 @@
|
|
|
5
5
|
import { answerCommand } from "./commands/answer.js";
|
|
6
6
|
import { askCommand } from "./commands/ask.js";
|
|
7
7
|
import { cleanCommand } from "./commands/clean.js";
|
|
8
|
+
import { configCommand } from "./commands/config.js";
|
|
8
9
|
import { doctorCommand } from "./commands/doctor.js";
|
|
9
10
|
import { exposeCommand } from "./commands/expose.js";
|
|
10
11
|
import { implementDoneCommand } from "./commands/implement-done.js";
|
|
@@ -16,7 +17,9 @@ import { statusCommand } from "./commands/status.js";
|
|
|
16
17
|
import { submitCommand } from "./commands/submit.js";
|
|
17
18
|
import { waitCommand } from "./commands/wait.js";
|
|
18
19
|
import { CliError, printJson } from "./output.js";
|
|
19
|
-
const USAGE = "usage: otacon <start|submit|wait|ask|answer|progress|implement-done|status|open|clean|install|doctor|expose> [options]"
|
|
20
|
+
const USAGE = "usage: otacon <start|submit|wait|ask|answer|progress|implement-done|status|open|config|clean|install|doctor|expose> [options]\n" +
|
|
21
|
+
" otacon config [open] open the Settings web UI in the browser\n" +
|
|
22
|
+
" otacon config get <key> print the merged value of one config key";
|
|
20
23
|
async function dispatch(command, argv) {
|
|
21
24
|
switch (command) {
|
|
22
25
|
case "start":
|
|
@@ -37,6 +40,8 @@ async function dispatch(command, argv) {
|
|
|
37
40
|
return statusCommand(argv);
|
|
38
41
|
case "open":
|
|
39
42
|
return openCommand(argv);
|
|
43
|
+
case "config":
|
|
44
|
+
return configCommand(argv);
|
|
40
45
|
case "clean":
|
|
41
46
|
return cleanCommand(argv);
|
|
42
47
|
case "install":
|
package/dist/cli/main.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"main.js","sourceRoot":"","sources":["../../src/cli/main.ts"],"names":[],"mappings":";AACA,+EAA+E;AAC/E,0EAA0E;AAC1E,iDAAiD;AAEjD,OAAO,EAAE,aAAa,EAAE,MAAM,sBAAsB,CAAC;AACrD,OAAO,EAAE,UAAU,EAAE,MAAM,mBAAmB,CAAC;AAC/C,OAAO,EAAE,YAAY,EAAE,MAAM,qBAAqB,CAAC;AACnD,OAAO,EAAE,aAAa,EAAE,MAAM,sBAAsB,CAAC;AACrD,OAAO,EAAE,aAAa,EAAE,MAAM,sBAAsB,CAAC;AACrD,OAAO,EAAE,oBAAoB,EAAE,MAAM,8BAA8B,CAAC;AACpE,OAAO,EAAE,cAAc,EAAE,MAAM,uBAAuB,CAAC;AACvD,OAAO,EAAE,WAAW,EAAE,M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