@ouro.bot/cli 0.1.0-alpha.510 → 0.1.0-alpha.511

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/changelog.json CHANGED
@@ -1,6 +1,14 @@
1
1
  {
2
2
  "_note": "This changelog is maintained as part of the PR/version-bump workflow. Agent-curated, not auto-generated. Agents read this file directly via read_file to understand what changed between versions.",
3
3
  "versions": [
4
+ {
5
+ "version": "0.1.0-alpha.511",
6
+ "changes": [
7
+ "Add `--json` flag to `ouro doctor`. Default human-readable output is unchanged; `--json` emits the full DoctorResult (categories + checks + summary) as pretty-printed JSON for piping into jq, dashboards, scheduled health monitors, or CI pipelines that want to alert on a doctor failure.",
8
+ "Same shape as the `--json` flag on the diagnostic family that's been growing alongside (session-playback / nerves-review / session-stats in their respective open PRs). Doctor was the asymmetric case — text-only output. With agent-private state coverage now landing in the doctor (Trips in #631, Mailroom in #632), structured output makes the doctor genuinely consumable by external tooling.",
9
+ "1 new test on the parse path (`doctor --json` → `{ kind: \"doctor\", json: true }`); the existing parse test is updated to match the new shape (`{ kind: \"doctor\", json: false }`). The exec-side change is a one-line ternary that picks `JSON.stringify(result, null, 2) + \"\\n\"` over `formatDoctorOutput(result)` when the flag is set. 83/83 doctor + parse tests pass."
10
+ ]
11
+ },
4
12
  {
5
13
  "version": "0.1.0-alpha.510",
6
14
  "changes": [
@@ -7066,7 +7066,9 @@ async function runOuroCli(args, deps = (0, cli_defaults_1.createDefaultOuroCliDe
7066
7066
  envPath: process.env.PATH ?? "",
7067
7067
  };
7068
7068
  const doctorResult = await (0, doctor_1.runDoctorChecks)(doctorDeps);
7069
- const output = (0, cli_render_doctor_1.formatDoctorOutput)(doctorResult);
7069
+ const output = command.json
7070
+ ? `${JSON.stringify(doctorResult, null, 2)}\n`
7071
+ : (0, cli_render_doctor_1.formatDoctorOutput)(doctorResult);
7070
7072
  deps.writeStdout(output);
7071
7073
  (0, runtime_1.emitNervesEvent)({
7072
7074
  component: "daemon",
@@ -1523,8 +1523,11 @@ function parseOuroCommand(args) {
1523
1523
  return parseSetupCommand(args.slice(1));
1524
1524
  if (head === "clone")
1525
1525
  return parseCloneCommand(args.slice(1));
1526
- if (head === "doctor")
1527
- return { kind: "doctor" };
1526
+ if (head === "doctor") {
1527
+ const tail = args.slice(1);
1528
+ const json = tail.includes("--json");
1529
+ return { kind: "doctor", json };
1530
+ }
1528
1531
  if (head === "bluebubbles")
1529
1532
  return parseBlueBubblesCommand(args.slice(1));
1530
1533
  const suggestion = (0, cli_help_1.suggestCommand)(head);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@ouro.bot/cli",
3
- "version": "0.1.0-alpha.510",
3
+ "version": "0.1.0-alpha.511",
4
4
  "main": "dist/heart/daemon/ouro-entry.js",
5
5
  "bin": {
6
6
  "cli": "dist/heart/daemon/ouro-bot-entry.js",