@cruxy/cli 0.8.0 → 0.9.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.
Files changed (66) hide show
  1. package/README.md +40 -13
  2. package/dist/agent/loop.d.ts +28 -1
  3. package/dist/agent/loop.js +36 -4
  4. package/dist/agent/prompts.d.ts +2 -0
  5. package/dist/agent/prompts.js +8 -0
  6. package/dist/approval/classify.js +26 -0
  7. package/dist/checkpoint/capture.d.ts +17 -0
  8. package/dist/checkpoint/capture.js +73 -0
  9. package/dist/checkpoint/git-store.d.ts +61 -0
  10. package/dist/checkpoint/git-store.js +171 -0
  11. package/dist/checkpoint/index.d.ts +6 -0
  12. package/dist/checkpoint/index.js +6 -0
  13. package/dist/checkpoint/restore.d.ts +23 -0
  14. package/dist/checkpoint/restore.js +195 -0
  15. package/dist/checkpoint/service.d.ts +80 -0
  16. package/dist/checkpoint/service.js +276 -0
  17. package/dist/checkpoint/shadow-store.d.ts +23 -0
  18. package/dist/checkpoint/shadow-store.js +93 -0
  19. package/dist/checkpoint/types.d.ts +117 -0
  20. package/dist/checkpoint/types.js +18 -0
  21. package/dist/cli/commands/checkpoint.d.ts +7 -0
  22. package/dist/cli/commands/checkpoint.js +31 -0
  23. package/dist/cli/commands/rollback.d.ts +10 -0
  24. package/dist/cli/commands/rollback.js +51 -0
  25. package/dist/cli/commands/run.js +10 -2
  26. package/dist/cli/program.js +4 -0
  27. package/dist/cli/repl.d.ts +2 -1
  28. package/dist/cli/repl.js +6 -3
  29. package/dist/cli/session-factory.d.ts +14 -1
  30. package/dist/cli/session-factory.js +87 -22
  31. package/dist/config/schema.d.ts +133 -0
  32. package/dist/config/schema.js +40 -0
  33. package/dist/errors/constructors.d.ts +25 -0
  34. package/dist/errors/constructors.js +86 -0
  35. package/dist/errors/types.d.ts +7 -0
  36. package/dist/errors/types.js +16 -0
  37. package/dist/indexing/walker.d.ts +11 -0
  38. package/dist/indexing/walker.js +11 -6
  39. package/dist/plan/execute.d.ts +8 -0
  40. package/dist/plan/execute.js +36 -22
  41. package/dist/plan/service.js +5 -1
  42. package/dist/plan/submit-plan.d.ts +4 -4
  43. package/dist/render/diff.js +27 -0
  44. package/dist/render/index.d.ts +2 -1
  45. package/dist/render/index.js +1 -0
  46. package/dist/render/plain-renderer.d.ts +7 -1
  47. package/dist/render/plain-renderer.js +26 -0
  48. package/dist/render/state.d.ts +31 -0
  49. package/dist/render/state.js +83 -0
  50. package/dist/render/tty-renderer.d.ts +41 -5
  51. package/dist/render/tty-renderer.js +150 -23
  52. package/dist/render/types.d.ts +85 -1
  53. package/dist/subagent/budget.d.ts +34 -0
  54. package/dist/subagent/budget.js +57 -0
  55. package/dist/subagent/index.d.ts +5 -0
  56. package/dist/subagent/index.js +5 -0
  57. package/dist/subagent/orchestrator.d.ts +67 -0
  58. package/dist/subagent/orchestrator.js +241 -0
  59. package/dist/subagent/registry-scope.d.ts +28 -0
  60. package/dist/subagent/registry-scope.js +63 -0
  61. package/dist/subagent/spawn-tool.d.ts +29 -0
  62. package/dist/subagent/spawn-tool.js +94 -0
  63. package/dist/subagent/types.d.ts +55 -0
  64. package/dist/subagent/types.js +1 -0
  65. package/dist/tools/types.d.ts +20 -2
  66. package/package.json +1 -1
@@ -76,6 +76,24 @@ export type ActionPreview =
76
76
  commitBody: string;
77
77
  prTitle: string;
78
78
  prBody: string;
79
+ }
80
+ /**
81
+ * The full blast radius of a checkpoint restore (C.32): every file rollback
82
+ * will recreate/revert/delete (as patch-style entries), plus the paths that
83
+ * changed since the checkpoint by something *other* than the tracked run —
84
+ * shown before the diff so the collapse cap can never hide them. Rollback
85
+ * covers working-tree files only; commits/pushes/PRs made during the run are
86
+ * out of scope (stated in the rendered note).
87
+ */
88
+ | {
89
+ type: "rollback";
90
+ checkpointId: string;
91
+ createdAt: string;
92
+ runSummary: string;
93
+ files: PatchFilePreview[];
94
+ externalPaths: string[];
95
+ /** The run executed shell commands, so per-file attribution is impossible. */
96
+ attributionUnknown: boolean;
79
97
  };
80
98
  /**
81
99
  * A side-effecting action a tool wants to take, passed to `ctx.approve`. The
@@ -83,12 +101,12 @@ export type ActionPreview =
83
101
  */
84
102
  export interface ApproveAction {
85
103
  /** The category of side effect being requested. */
86
- kind: "write" | "edit" | "shell" | "patch" | "vcs";
104
+ kind: "write" | "edit" | "shell" | "patch" | "vcs" | "rollback";
87
105
  /** Absolute resolved path the action targets (write/edit). */
88
106
  path?: string;
89
107
  /** The command to run (shell). */
90
108
  command?: string;
91
- /** Exact-change preview rendered above the prompt (write/edit/patch/vcs). */
109
+ /** Exact-change preview rendered above the prompt (write/edit/patch/vcs/rollback). */
92
110
  preview?: ActionPreview;
93
111
  }
94
112
  /**
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@cruxy/cli",
3
- "version": "0.8.0",
3
+ "version": "0.9.0",
4
4
  "description": "an agentic coding CLI",
5
5
  "type": "module",
6
6
  "bin": {