@letterstory/cli 0.92.0 → 0.93.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/lib/cli.mjs CHANGED
@@ -57,7 +57,7 @@ import {
57
57
  } from "./commands.mjs";
58
58
 
59
59
  // Keep in sync with cli/package.json.
60
- export const VERSION = "0.92.0";
60
+ export const VERSION = "0.93.0";
61
61
 
62
62
  // Flags that never take a value. Listing them explicitly means `deploy get --json <id>`
63
63
  // can't accidentally swallow the id as --json's value. Every `type: "bool"` flag (and its
@@ -779,23 +779,24 @@ function formatPrimitivePlan(ctx) {
779
779
  // A part of its parent's setup prints indented under it.
780
780
  const pad = item.parent ? " " : "";
781
781
  const mark = item.status === "exists" ? "running " : "proposed";
782
- lines.push(`${pad}${mark} ${item.title}`);
782
+ lines.push(`${pad}${mark} ${item.title}${item.gates?.length ? ` [${item.gates.join(", ")}]` : ""}`);
783
783
  lines.push(
784
784
  item.status === "exists"
785
785
  ? `${pad} already: ${item.existing.map((e) => e.name).join(", ")}`
786
786
  : `${pad} ${item.detail}`
787
787
  );
788
- if (item.call) {
788
+ if (item.record) {
789
789
  lines.push(
790
- `${pad} ${ctx.bin} call ${item.call.tool} --args ${shellQuote(JSON.stringify(item.call.args))}`
790
+ `${pad} ${item.record.section === "settings" ? "~ settings.defaultKernel" : `+ ${item.record.section} "${item.record.name}"`}`
791
791
  );
792
- for (const [arg, ref] of Object.entries(item.refs ?? {})) {
793
- lines.push(`${pad} with ${arg} = ${ref.field} from ${ref.item}`);
794
- }
795
- if (item.after?.length) lines.push(`${pad} after: ${item.after.join(", ")}`);
796
- if (item.poll) lines.push(`${pad} then poll: ${item.poll.tool}`);
797
792
  }
798
793
  }
794
+ const gates = [...new Set(plan.items.flatMap((i) => (i.record ? (i.gates ?? []) : [])))].sort();
795
+ lines.push("");
796
+ lines.push("The plan is an org-config bundle. Save it and apply it like any other:");
797
+ lines.push(` ${ctx.bin} ${recipeName(ctx)} primitives --json | jq .plan.config > plan.json`);
798
+ lines.push(` ${ctx.bin} org apply plan.json --dry-run${gates.length ? ` --allow ${gates.join(",")}` : ""}`);
799
+ lines.push("Drop a record from plan.json to leave that item out.");
799
800
  return lines.join("\n");
800
801
  };
801
802
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@letterstory/cli",
3
- "version": "0.92.0",
3
+ "version": "0.93.0",
4
4
  "description": "Spin up and manage Letterstory phantom blogs from your terminal.",
5
5
  "type": "module",
6
6
  "license": "UNLICENSED",