@cleocode/cleo 2026.4.145 → 2026.4.146

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/dist/cli/index.js CHANGED
@@ -55718,6 +55718,74 @@ var reasonCommand = defineCommand({
55718
55718
  }
55719
55719
  });
55720
55720
 
55721
+ // packages/cleo/src/cli/commands/reconcile.ts
55722
+ import { release } from "@cleocode/core";
55723
+ var releaseSubcommand = defineCommand({
55724
+ meta: {
55725
+ name: "release",
55726
+ description: "Run post-release invariants for a release tag"
55727
+ },
55728
+ args: {
55729
+ tag: {
55730
+ type: "string",
55731
+ description: "Release tag to reconcile (e.g. v2026.4.145)",
55732
+ required: true
55733
+ },
55734
+ "dry-run": {
55735
+ type: "boolean",
55736
+ description: "Preview mutations without writing to tasks.db or audit log",
55737
+ default: false
55738
+ },
55739
+ json: {
55740
+ type: "boolean",
55741
+ description: "Emit raw JSON instead of human-readable summary",
55742
+ default: false
55743
+ }
55744
+ },
55745
+ async run({ args }) {
55746
+ const dryRun = args["dry-run"] === true;
55747
+ const report = await release.runInvariants(args.tag, {
55748
+ dryRun,
55749
+ cwd: process.cwd()
55750
+ });
55751
+ if (args.json) {
55752
+ process.stdout.write(`${JSON.stringify(report, null, 2)}
55753
+ `);
55754
+ } else {
55755
+ const lines = [];
55756
+ lines.push(`reconcile release ${report.tag}${dryRun ? " (dry-run)" : ""}`);
55757
+ lines.push(
55758
+ ` total: processed=${report.processed} reconciled=${report.reconciled} unreconciled=${report.unreconciled} errors=${report.errors}`
55759
+ );
55760
+ for (const r of report.results) {
55761
+ lines.push(` [${r.severity}] ${r.id}: ${r.message}`);
55762
+ }
55763
+ process.stdout.write(`${lines.join("\n")}
55764
+ `);
55765
+ }
55766
+ if (report.errors > 0) {
55767
+ process.exit(1);
55768
+ }
55769
+ if (report.unreconciled > 0) {
55770
+ process.exit(2);
55771
+ }
55772
+ }
55773
+ });
55774
+ var reconcileCommand2 = defineCommand({
55775
+ meta: {
55776
+ name: "reconcile",
55777
+ description: "Reconcile state against external sources (release tags, schema, etc.)"
55778
+ },
55779
+ subCommands: {
55780
+ release: releaseSubcommand
55781
+ },
55782
+ async run({ cmd, rawArgs }) {
55783
+ const firstArg = rawArgs?.find((a) => !a.startsWith("-"));
55784
+ if (firstArg && cmd.subCommands && firstArg in cmd.subCommands) return;
55785
+ await showUsage(cmd);
55786
+ }
55787
+ });
55788
+
55721
55789
  // packages/cleo/src/cli/commands/refresh-memory.ts
55722
55790
  import { getProjectRoot as getProjectRoot27 } from "@cleocode/core";
55723
55791
  var refreshMemoryCommand = defineCommand({
@@ -60146,7 +60214,7 @@ var linksCommand2 = defineCommand({
60146
60214
  );
60147
60215
  }
60148
60216
  });
60149
- var reconcileCommand2 = defineCommand({
60217
+ var reconcileCommand3 = defineCommand({
60150
60218
  meta: {
60151
60219
  name: "reconcile",
60152
60220
  description: "Reconcile external tasks from a JSON file against CLEO tasks"
@@ -60199,7 +60267,7 @@ var syncCommand5 = defineCommand({
60199
60267
  meta: { name: "sync", description: "External task synchronisation management" },
60200
60268
  subCommands: {
60201
60269
  links: linksCommand2,
60202
- reconcile: reconcileCommand2
60270
+ reconcile: reconcileCommand3
60203
60271
  },
60204
60272
  async run({ cmd, rawArgs }) {
60205
60273
  const firstArg = rawArgs?.find((a) => !a.startsWith("-"));
@@ -61813,6 +61881,7 @@ subCommands["playbook"] = playbookCommand;
61813
61881
  subCommands["promote"] = promoteCommand;
61814
61882
  subCommands["provider"] = providerCommand;
61815
61883
  subCommands["reason"] = reasonCommand;
61884
+ subCommands["reconcile"] = reconcileCommand2;
61816
61885
  subCommands["refresh-memory"] = refreshMemoryCommand;
61817
61886
  subCommands["relates"] = relatesCommand;
61818
61887
  subCommands["release"] = releaseCommand;