@letterstory/cli 0.177.3 → 0.177.5
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 +5 -1
- package/lib/commands/build.mjs +19 -1
- package/lib/commands/domains.mjs +13 -0
- package/package.json +1 -1
package/lib/cli.mjs
CHANGED
|
@@ -87,7 +87,7 @@ import {
|
|
|
87
87
|
import { fetchParkedSections, withoutParked } from "./parked.mjs";
|
|
88
88
|
|
|
89
89
|
// Matches cli/package.json; publish-cli.yml rewrites both to the published version.
|
|
90
|
-
export const VERSION = "0.177.
|
|
90
|
+
export const VERSION = "0.177.5";
|
|
91
91
|
|
|
92
92
|
/** The exit code for a gate refusal (CARD_REQUIRED, PAYMENT_FAILED, OUT_OF_TOKENS): 1 is a plain error. */
|
|
93
93
|
export const EXIT_PAYMENT_REQUIRED = 3;
|
|
@@ -152,6 +152,8 @@ export const BOOLEAN_FLAGS = new Set([
|
|
|
152
152
|
// build: repeat an open build's ask; post its progress in the org's Slack channel.
|
|
153
153
|
"again",
|
|
154
154
|
"plan-only",
|
|
155
|
+
// build: the words are a request to build, never read as a question.
|
|
156
|
+
"build-it",
|
|
155
157
|
// build: every change reads Letter's tools from its sandbox.
|
|
156
158
|
"primitives-access",
|
|
157
159
|
// build list: only Build's Archived tab (--open, already listed, is its Open tab).
|
|
@@ -229,6 +231,8 @@ export const BOOLEAN_FLAGS = new Set([
|
|
|
229
231
|
"verbose",
|
|
230
232
|
"no-color",
|
|
231
233
|
"dry-run",
|
|
234
|
+
// domains buy --no-spend: only when it buys nothing.
|
|
235
|
+
"no-spend",
|
|
232
236
|
// admin demo list --enrollable, show --moves, set --enroll|--unenroll
|
|
233
237
|
"enrollable",
|
|
234
238
|
"moves",
|
package/lib/commands/build.mjs
CHANGED
|
@@ -42,6 +42,10 @@ const ARGS = {
|
|
|
42
42
|
},
|
|
43
43
|
// The words after `build`, or --prompt for a longer ask.
|
|
44
44
|
prompt: { value: (flags, positionals) => flagStr(flags.prompt) ?? (positionals.join(" ").trim() || undefined) },
|
|
45
|
+
// --ask "<words>": the person's own words, when --prompt was written from them.
|
|
46
|
+
ask: "ask",
|
|
47
|
+
// --build-it: the words are a request to build, never read as a question.
|
|
48
|
+
asked_to_build: { flag: "build-it", type: "bool" },
|
|
45
49
|
domain: "site",
|
|
46
50
|
// --subject host/path (repeatable): the pages it is about.
|
|
47
51
|
subjects: { flag: "subject", type: "list" },
|
|
@@ -50,7 +54,7 @@ const ARGS = {
|
|
|
50
54
|
files: { value: (_flags, _positionals, extra) => (extra.files?.length ? extra.files : undefined) },
|
|
51
55
|
delivery: { flag: "action", enum: ["build", "build_pr", "build_merge", "slack", "linear"] },
|
|
52
56
|
notify_slack: { flag: "notify-slack", type: "bool" },
|
|
53
|
-
// --primitives-access:
|
|
57
|
+
// --primitives-access: its change reads Letter's tools from its sandbox (a read-only MCP key beside the repo).
|
|
54
58
|
primitives_access: { flag: "primitives-access", type: "bool" },
|
|
55
59
|
harness: { flag: "harness", enum: ["letterpress-1", "claude-code", "codex"] },
|
|
56
60
|
// --branch <name>: where its changes start and its pull requests go; omitted, the branch that builds the site.
|
|
@@ -67,6 +71,17 @@ const ARGS = {
|
|
|
67
71
|
recipe: "recipe",
|
|
68
72
|
// Preserve the account-specific task selected by the Plan.
|
|
69
73
|
fit_run: "fit-run",
|
|
74
|
+
// --accepted-quote '<json>': the price the Ideas row showed, echoed to accept what it buys.
|
|
75
|
+
accepted_quote: {
|
|
76
|
+
value: (flags) => {
|
|
77
|
+
if (typeof flags["accepted-quote"] !== "string") return undefined;
|
|
78
|
+
try {
|
|
79
|
+
return JSON.parse(flags["accepted-quote"]);
|
|
80
|
+
} catch {
|
|
81
|
+
throw new CliError("--accepted-quote takes JSON.");
|
|
82
|
+
}
|
|
83
|
+
},
|
|
84
|
+
},
|
|
70
85
|
// --new-site: a website or app of its own, built and hosted on its own domain (deploy create's path).
|
|
71
86
|
new_site: { flag: "new-site", type: "bool" },
|
|
72
87
|
// --new-site --look-like linear.app,supabase.com: other companies' sites to model its look after.
|
|
@@ -235,10 +250,13 @@ async function buildStart(ctx) {
|
|
|
235
250
|
const { client, flags, io } = ctx;
|
|
236
251
|
refuseUnknownFlags(ctx, {}, [
|
|
237
252
|
"prompt",
|
|
253
|
+
"ask",
|
|
254
|
+
"build-it",
|
|
238
255
|
"site",
|
|
239
256
|
"subject",
|
|
240
257
|
"recipe",
|
|
241
258
|
"fit-run",
|
|
259
|
+
"accepted-quote",
|
|
242
260
|
"action",
|
|
243
261
|
"notify-slack",
|
|
244
262
|
"harness",
|
package/lib/commands/domains.mjs
CHANGED
|
@@ -45,6 +45,19 @@ export const ARGS = {
|
|
|
45
45
|
register_domain: {
|
|
46
46
|
domain: { value: (flags, positionals) => stripScheme(requirePositional(positionals, 0, "domain")) },
|
|
47
47
|
dry_run: { flag: "dry-run", type: "bool" },
|
|
48
|
+
// --no-spend: only when it buys nothing (held already, or a phantom's); refused rather than bought.
|
|
49
|
+
no_spend: { flag: "no-spend", type: "bool" },
|
|
50
|
+
// --accepted-quote '<json>': the `quote` a dry run returned, echoed to buy at that price.
|
|
51
|
+
accepted_quote: {
|
|
52
|
+
value: (flags) => {
|
|
53
|
+
if (typeof flags["accepted-quote"] !== "string") return undefined;
|
|
54
|
+
try {
|
|
55
|
+
return JSON.parse(flags["accepted-quote"]);
|
|
56
|
+
} catch {
|
|
57
|
+
throw new CliError("--accepted-quote takes JSON.");
|
|
58
|
+
}
|
|
59
|
+
},
|
|
60
|
+
},
|
|
48
61
|
},
|
|
49
62
|
// `domains plan <domain>` — the scan row's search and its monthly searches, when you have them.
|
|
50
63
|
plan_domain_site: {
|