@koda-sl/baker-cli 0.343.0-dev.4845130c3 → 0.343.0-dev.acf96fa0f

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/README.md CHANGED
@@ -118,14 +118,12 @@ Use `--output` to change format:
118
118
 
119
119
  | Format | Description | Best for | Available on |
120
120
  |---------|------------------------------------|--------------------|--------------|
121
- | `json` | Structured JSON envelope (default) | AI agents | every command that prints the envelope |
122
- | `files` | Tab-separated, one row per result | Piping / shell | commands whose `baker schema` lists `output` |
123
- | `md` | Markdown table | Human reading | commands whose `baker schema` lists `output` |
121
+ | `json` | Structured JSON envelope (default) | AI agents | every command |
122
+ | `files` | Tab-separated, one row per result | Piping / shell | every command |
123
+ | `md` | Markdown table | Human reading | every command |
124
124
  | `csv` | RFC 4180 comma-separated values | Analysis tools | `baker research …` only |
125
125
  | `jsonl` | One JSON object per line | Streaming/appending | `baker research …` only |
126
126
 
127
- `--output json` is accepted even by a command that declares no `--output`: the envelope is already what it prints, and on a command whose default is a readable view (`baker tags list`, the `draft` commands) it becomes that command's `--json`. The few commands that print only text — `baker analytics sending-events`, `baker canvas run` and `rerun` — refuse it, as a command without its own `--output` refuses `md` and `files`.
128
-
129
127
  `csv` and `jsonl` are implemented by the research family alone. Asking any other command for them — or for a format that does not exist — falls back to the JSON envelope and says so on stderr, rather than printing nothing and exiting 0.
130
128
 
131
129
  `files` and `md` print rows and nothing else, so any `hints` or data-quality note the envelope carries is written to **stderr** instead. Reading stdout alone still gives you clean, parseable rows.
@@ -611,16 +609,11 @@ baker ads google keywords update <criterion-id> --customer-id 1234567890 --clear
611
609
  baker ads google ads create --customer-id 1234567890 --ad-group-ref g_temp_<adgroup> \
612
610
  --headlines "Fast Widgets,Buy Online,Free Shipping" --descriptions "Best widgets around.,Ships tomorrow." \
613
611
  --final-url https://example.com
614
- # Copy with commas in it — repeat the flag once per item (or quote the item: '"Fast, free quotes",Book today')
615
- baker ads google ads create --customer-id 1234567890 --ad-group-ref g_temp_<adgroup> \
616
- --headlines "Fast Widgets,Buy Online,Free Shipping" \
617
- --descriptions "Calls, messages and bookings in one place." --descriptions "Ships tomorrow, free." \
618
- --final-url https://example.com
619
612
  # Responsive display ad — images are fields on the ad; register each image as an asset first (returns a g_temp_* ref)
620
613
  baker ads google assets create --customer-id 1234567890 --file '{"type":"image","imageId":"<baker_image_id>","name":"Hero"}'
621
614
  baker ads google ads create --customer-id 1234567890 --ad-group-ref g_temp_<adgroup> --format responsiveDisplay \
622
615
  --headlines "Come back and save" --long-headline "Finish signing up and get 20% off" \
623
- --descriptions '"Fast setup, no card required"' --business-name "Acme" --final-url https://example.com \
616
+ --descriptions "Fast setup, no card required" --business-name "Acme" --final-url https://example.com \
624
617
  --marketing-images g_temp_<img_landscape> --square-marketing-images g_temp_<img_square> --logo-images g_temp_<img_logo>
625
618
  # Video ad — the YouTube video is its own asset first, then referenced by --video-assets
626
619
  baker ads google assets create --customer-id 1234567890 --file '{"type":"youtubeVideo","youtubeVideoId":"dQw4w9WgXcQ"}'
@@ -8,7 +8,11 @@
8
8
  "default_duration": 3,
9
9
  "inputs": {},
10
10
  "params": {
11
- "logo_svg": { "kind": "string", "default": "", "description": "Raw inline <svg>…</svg> wordmark with fill set to text_color (optional)." },
11
+ "logo_svg": {
12
+ "kind": "string",
13
+ "default": "",
14
+ "description": "Raw inline <svg>…</svg> wordmark with fill set to text_color (optional)."
15
+ },
12
16
  "headline": { "kind": "string", "required": true, "description": "Closing line." },
13
17
  "cta_text": { "kind": "string", "default": "", "description": "Call-to-action pill label (optional)." },
14
18
  "bg_color": { "kind": "color", "default": "#0b1020" },
@@ -9,10 +9,20 @@
9
9
  "inputs": {},
10
10
  "params": {
11
11
  "title": { "kind": "string", "default": "", "description": "Optional heading above the list." },
12
- "features": { "kind": "json", "required": true, "description": "Array of 1–6 short labels, e.g. [\"No setup fees\", \"Cancel anytime\"]." },
12
+ "features": {
13
+ "kind": "json",
14
+ "required": true,
15
+ "description": "Array of 1–6 short labels, e.g. [\"No setup fees\", \"Cancel anytime\"]."
16
+ },
13
17
  "text_color": { "kind": "color", "default": "#0b1020" },
14
18
  "accent_color": { "kind": "color", "default": "#1f9d57", "description": "Check-circle fill." },
15
19
  "check_color": { "kind": "color", "default": "#ffffff", "description": "The check mark inside the circle." },
16
- "stagger_s": { "kind": "number", "default": 0.18, "min": 0.02, "max": 1, "description": "Seconds between each item." }
20
+ "stagger_s": {
21
+ "kind": "number",
22
+ "default": 0.18,
23
+ "min": 0.02,
24
+ "max": 1,
25
+ "description": "Seconds between each item."
26
+ }
17
27
  }
18
28
  }
@@ -13,6 +13,12 @@
13
13
  "bar_color": { "kind": "color", "default": "#0b1020" },
14
14
  "text_color": { "kind": "color", "default": "#ffffff" },
15
15
  "accent_color": { "kind": "color", "default": "#5b8cff", "description": "The leading accent block." },
16
- "from_bottom_px": { "kind": "integer", "default": 220, "min": 0, "max": 1600, "description": "Distance of the bar from the bottom edge." }
16
+ "from_bottom_px": {
17
+ "kind": "integer",
18
+ "default": 220,
19
+ "min": 0,
20
+ "max": 1600,
21
+ "description": "Distance of the bar from the bottom edge."
22
+ }
17
23
  }
18
24
  }
@@ -15,12 +15,34 @@
15
15
  }
16
16
  },
17
17
  "params": {
18
- "headline": { "kind": "string", "default": "", "description": "Big line on the content stage (what the presenter is showing)." },
19
- "claim": { "kind": "string", "default": "", "description": "Short proof/claim on the floating glass card (optional)." },
18
+ "headline": {
19
+ "kind": "string",
20
+ "default": "",
21
+ "description": "Big line on the content stage (what the presenter is showing)."
22
+ },
23
+ "claim": {
24
+ "kind": "string",
25
+ "default": "",
26
+ "description": "Short proof/claim on the floating glass card (optional)."
27
+ },
20
28
  "caption": { "kind": "string", "default": "", "description": "A caption line in the lower band (optional)." },
21
- "pip_at_s": { "kind": "number", "default": 2, "min": 0, "max": 30, "description": "When the presenter shrinks to the corner pill." },
22
- "bg_color": { "kind": "color", "default": "#0b1020", "description": "Content-stage background (behind the presenter)." },
29
+ "pip_at_s": {
30
+ "kind": "number",
31
+ "default": 2,
32
+ "min": 0,
33
+ "max": 30,
34
+ "description": "When the presenter shrinks to the corner pill."
35
+ },
36
+ "bg_color": {
37
+ "kind": "color",
38
+ "default": "#0b1020",
39
+ "description": "Content-stage background (behind the presenter)."
40
+ },
23
41
  "text_color": { "kind": "color", "default": "#ffffff" },
24
- "accent_color": { "kind": "color", "default": "#5b8cff", "description": "Headline accent + caption underline + pill ring tint." }
42
+ "accent_color": {
43
+ "kind": "color",
44
+ "default": "#5b8cff",
45
+ "description": "Headline accent + caption underline + pill ring tint."
46
+ }
25
47
  }
26
48
  }
package/dist/cli.js CHANGED
@@ -17043,113 +17043,6 @@ Examples:
17043
17043
  // src/commands/ads/google/write-commands.ts
17044
17044
  import { defineCommand as defineCommand31 } from "citty";
17045
17045
 
17046
- // src/commands/ads/google/ad-copy-flags.ts
17047
- var AD_COPY_LIST_FLAGS = ["headlines", "descriptions", "long-headlines"];
17048
- var AD_COPY_LIST_USAGE = `repeat the flag once per item, or pass one comma-separated list and wrap an item that contains a comma in double quotes: '"Fast, free quotes",Book today'. A flag given once is read as a list, so a lone item with a comma needs its double quotes too: '"Fast, free quotes"'`;
17049
- function skipBlanks(value, at) {
17050
- let i = at;
17051
- while (value[i] === " " || value[i] === " ") i++;
17052
- return i;
17053
- }
17054
- function readQuotedField(value, open, flag) {
17055
- let text2 = "";
17056
- let j = open + 1;
17057
- while (!(value[j] === '"' && value[j + 1] !== '"')) {
17058
- if (j >= value.length) {
17059
- failWriteValidation(`--${flag} has a quote with no closing quote: ${value} \u2014 ${AD_COPY_LIST_USAGE}`);
17060
- }
17061
- text2 += value[j];
17062
- j += value[j] === '"' ? 2 : 1;
17063
- }
17064
- const after = skipBlanks(value, j + 1);
17065
- if (after < value.length && value[after] !== ",") {
17066
- failWriteValidation(
17067
- `--${flag}: text follows the closing quote of "${text2}" \u2014 a quoted item must end at a comma. To put a quote inside an item, double it ("") or ${AD_COPY_LIST_USAGE}`
17068
- );
17069
- }
17070
- return { text: text2, next: after + 1 };
17071
- }
17072
- function splitQuotedList(value, flag) {
17073
- const fields = [];
17074
- let i = 0;
17075
- while (i <= value.length) {
17076
- const start = skipBlanks(value, i);
17077
- if (value[start] === '"') {
17078
- const { text: text2, next } = readQuotedField(value, start, flag);
17079
- fields.push({ text: text2, quoted: true });
17080
- i = next;
17081
- } else {
17082
- const comma = value.indexOf(",", start);
17083
- const end = comma === -1 ? value.length : comma;
17084
- fields.push({ text: value.slice(start, end), quoted: false });
17085
- i = end + 1;
17086
- }
17087
- }
17088
- const several = fields.length > 1;
17089
- return fields.map((field) => ({ text: field.text.trim(), splitAtComma: several && !field.quoted }));
17090
- }
17091
- function jsonStringArray(value) {
17092
- if (!value.startsWith("[")) return void 0;
17093
- try {
17094
- const parsed = JSON.parse(value);
17095
- return Array.isArray(parsed) && parsed.every((v) => typeof v === "string") ? parsed : void 0;
17096
- } catch {
17097
- return void 0;
17098
- }
17099
- }
17100
- function parseCopyList(value, flag) {
17101
- let items;
17102
- if (Array.isArray(value)) {
17103
- items = value.filter((v) => typeof v === "string").map((v) => ({ text: v.trim(), splitAtComma: false }));
17104
- } else if (typeof value === "string") {
17105
- const trimmed = value.trim();
17106
- const json = jsonStringArray(trimmed);
17107
- items = json ? json.map((v) => ({ text: v.trim(), splitAtComma: false })) : splitQuotedList(trimmed, flag);
17108
- } else {
17109
- return void 0;
17110
- }
17111
- const kept = items.filter((item) => item.text.length > 0);
17112
- return kept.length > 0 ? kept : void 0;
17113
- }
17114
- function copyListFlag(value, flag) {
17115
- return parseCopyList(value, flag)?.map((item) => item.text);
17116
- }
17117
- function refuseDashLedValue(rawArgs, flag) {
17118
- for (let i = 0; i < rawArgs.length - 1; i++) {
17119
- if (rawArgs[i] === "--") return;
17120
- const value = rawArgs[i + 1];
17121
- if (rawArgs[i] === `--${flag}` && value?.startsWith("-")) {
17122
- failWriteValidation(
17123
- `--${flag} is followed by "${value}", which starts with a dash and is read as another flag, not as copy. Join copy that starts with a dash to its flag with =: --${flag}="${value}"`
17124
- );
17125
- }
17126
- }
17127
- }
17128
- function withRepeatedCopyFlags(args5, rawArgs) {
17129
- const out = { ...args5 };
17130
- for (const flag of AD_COPY_LIST_FLAGS) {
17131
- refuseDashLedValue(rawArgs ?? [], flag);
17132
- const values = repeatedFlagValues(rawArgs ?? [], flag);
17133
- if (values.length > 1) {
17134
- out[flag] = values;
17135
- }
17136
- }
17137
- return out;
17138
- }
17139
- function copyListSplitHints(args5) {
17140
- const hints2 = [];
17141
- for (const flag of AD_COPY_LIST_FLAGS) {
17142
- const items = parseCopyList(args5[flag], flag) ?? [];
17143
- const fragments = items.filter((item, index) => index > 0 && item.splitAtComma && new RegExp("^\\p{Ll}", "u").test(item.text));
17144
- if (fragments.length > 0) {
17145
- hints2.push(
17146
- `--${flag}: ${fragments.map((f) => `"${f.text}"`).join(", ")} starts in lowercase \u2014 it looks like the end of one item cut at a comma. Check the staged copy; if it was one item, fix this op in place with \`draft amend <ref>\` (the ref this response returned) rather than staging it again, which would leave the cut copy staged too \u2014 ${AD_COPY_LIST_USAGE}.`
17147
- );
17148
- }
17149
- }
17150
- return hints2;
17151
- }
17152
-
17153
17046
  // src/commands/ads/google/conversion-upload-command.ts
17154
17047
  import { readFileSync as readFileSync4 } from "fs";
17155
17048
  import { defineCommand as defineCommand30 } from "citty";
@@ -18205,10 +18098,10 @@ var keywordListsCommand = defineCommand31({
18205
18098
  }
18206
18099
  });
18207
18100
  function rsaContentFromFlags(args5) {
18208
- const headlines = copyListFlag(args5.headlines, "headlines");
18209
- const descriptions = copyListFlag(args5.descriptions, "descriptions");
18101
+ const headlines = listFlag(args5.headlines);
18102
+ const descriptions = listFlag(args5.descriptions);
18210
18103
  if (!headlines || !descriptions) {
18211
- failWriteValidation("responsive search ads need --headlines and --descriptions, or use --file");
18104
+ failWriteValidation("responsive search ads need --headlines and --descriptions (comma-separated), or use --file");
18212
18105
  }
18213
18106
  const finalUrls = listFlag(args5["final-url"]);
18214
18107
  if (!finalUrls) {
@@ -18228,11 +18121,11 @@ function rdaContentFromFlags(args5, base) {
18228
18121
  format: "responsiveDisplay",
18229
18122
  ...base !== null && typeof base === "object" && !Array.isArray(base) ? base : {}
18230
18123
  };
18231
- const headlines = copyListFlag(args5.headlines, "headlines");
18124
+ const headlines = listFlag(args5.headlines);
18232
18125
  if (headlines) {
18233
18126
  content.headlines = headlines.map((text2) => ({ text: text2 }));
18234
18127
  }
18235
- const descriptions = copyListFlag(args5.descriptions, "descriptions");
18128
+ const descriptions = listFlag(args5.descriptions);
18236
18129
  if (descriptions) {
18237
18130
  content.descriptions = descriptions.map((text2) => ({ text: text2 }));
18238
18131
  }
@@ -18283,11 +18176,11 @@ function demandGenContentFromFlags(args5, base) {
18283
18176
  if (typeof args5["ad-name"] === "string") {
18284
18177
  content.name = args5["ad-name"];
18285
18178
  }
18286
- const headlines = copyListFlag(args5.headlines, "headlines");
18179
+ const headlines = listFlag(args5.headlines);
18287
18180
  if (headlines) {
18288
18181
  content.headlines = headlines.map((text2) => ({ text: text2 }));
18289
18182
  }
18290
- const descriptions = copyListFlag(args5.descriptions, "descriptions");
18183
+ const descriptions = listFlag(args5.descriptions);
18291
18184
  if (descriptions) {
18292
18185
  content.descriptions = descriptions.map((text2) => ({ text: text2 }));
18293
18186
  }
@@ -18320,15 +18213,15 @@ function demandGenVideoContentFromFlags(args5, base) {
18320
18213
  if (typeof args5["ad-name"] === "string") {
18321
18214
  content.name = args5["ad-name"];
18322
18215
  }
18323
- const headlines = copyListFlag(args5.headlines, "headlines");
18216
+ const headlines = listFlag(args5.headlines);
18324
18217
  if (headlines) {
18325
18218
  content.headlines = headlines.map((text2) => ({ text: text2 }));
18326
18219
  }
18327
- const longHeadlines = copyListFlag(args5["long-headlines"], "long-headlines");
18220
+ const longHeadlines = listFlag(args5["long-headlines"]);
18328
18221
  if (longHeadlines) {
18329
18222
  content.longHeadlines = longHeadlines.map((text2) => ({ text: text2 }));
18330
18223
  }
18331
- const descriptions = copyListFlag(args5.descriptions, "descriptions");
18224
+ const descriptions = listFlag(args5.descriptions);
18332
18225
  if (descriptions) {
18333
18226
  content.descriptions = descriptions.map((text2) => ({ text: text2 }));
18334
18227
  }
@@ -18358,11 +18251,11 @@ function appContentFromFlags(args5, base) {
18358
18251
  format: "app",
18359
18252
  ...base !== null && typeof base === "object" && !Array.isArray(base) ? base : {}
18360
18253
  };
18361
- const headlines = copyListFlag(args5.headlines, "headlines");
18254
+ const headlines = listFlag(args5.headlines);
18362
18255
  if (headlines) {
18363
18256
  content.headlines = headlines.map((text2) => ({ text: text2 }));
18364
18257
  }
18365
- const descriptions = copyListFlag(args5.descriptions, "descriptions");
18258
+ const descriptions = listFlag(args5.descriptions);
18366
18259
  if (descriptions) {
18367
18260
  content.descriptions = descriptions.map((text2) => ({ text: text2 }));
18368
18261
  }
@@ -18464,13 +18357,10 @@ var adContentArgs = {
18464
18357
  type: "string",
18465
18358
  description: "responsiveSearch (default) | responsiveDisplay | call | app | video | demandGen | demandGenVideo"
18466
18359
  },
18467
- headlines: {
18468
- type: "string",
18469
- description: `Headlines (RSA/RDA/demandGen/demandGenVideo/app) \u2014 ${AD_COPY_LIST_USAGE}`
18470
- },
18360
+ headlines: { type: "string", description: "Comma-separated headlines (RSA/RDA/demandGen/demandGenVideo/app)" },
18471
18361
  descriptions: {
18472
18362
  type: "string",
18473
- description: `Descriptions (RSA/RDA/demandGen/demandGenVideo/app) \u2014 ${AD_COPY_LIST_USAGE}`
18363
+ description: "Comma-separated descriptions (RSA/RDA/demandGen/demandGenVideo/app)"
18474
18364
  },
18475
18365
  path1: { type: "string" },
18476
18366
  path2: { type: "string" },
@@ -18481,7 +18371,7 @@ var adContentArgs = {
18481
18371
  },
18482
18372
  "long-headlines": {
18483
18373
  type: "string",
18484
- description: `Long headlines, up to 5 of 90 chars (demandGenVideo \u2014 no other format has them) \u2014 ${AD_COPY_LIST_USAGE}`
18374
+ description: "Comma-separated long headlines, up to 5 of 90 chars (demandGenVideo \u2014 no other format has them)"
18485
18375
  },
18486
18376
  "business-name": { type: "string", description: "Business name (responsiveDisplay/demandGen/demandGenVideo)" },
18487
18377
  "marketing-images": {
@@ -18532,22 +18422,16 @@ var adsCommand = defineCommand31({
18532
18422
  ...adContentArgs,
18533
18423
  status: { type: "string" }
18534
18424
  },
18535
- run: async ({ args: parsedArgs, rawArgs }) => {
18536
- const args5 = withRepeatedCopyFlags(parsedArgs, rawArgs);
18425
+ run: async ({ args: args5 }) => {
18537
18426
  const customerId = requireCustomerId(args5);
18538
18427
  const file = loadJsonFileArg(args5.file);
18539
18428
  const format = args5.format ?? "responsiveSearch";
18540
18429
  const content = adContentFromFlags(args5, format, file.content);
18541
- await stageCreate(
18542
- "google.ad.create",
18543
- customerId,
18544
- {
18545
- adGroup: requireStringFlag(args5["ad-group-ref"] ?? file.adGroup, "--ad-group-ref"),
18546
- status: args5.status ?? file.status,
18547
- content
18548
- },
18549
- copyListSplitHints(args5)
18550
- );
18430
+ await stageCreate("google.ad.create", customerId, {
18431
+ adGroup: requireStringFlag(args5["ad-group-ref"] ?? file.adGroup, "--ad-group-ref"),
18432
+ status: args5.status ?? file.status,
18433
+ content
18434
+ });
18551
18435
  }
18552
18436
  }),
18553
18437
  update: defineCommand31({
@@ -18556,8 +18440,7 @@ var adsCommand = defineCommand31({
18556
18440
  description: "Stage an ad update. Any content change needs --format plus EVERY required field of that format (or --file with the complete content) \u2014 a field you send replaces its current value wholesale, so a list you pass must already include the entries you want to keep. Optional asset lists you omit entirely are left untouched on the ad. Status-only changes need neither --format nor content flags."
18557
18441
  },
18558
18442
  args: { ...customerIdArg, ...fileArg, ...adContentArgs, status: { type: "string" } },
18559
- run: async ({ args: parsedArgs, rawArgs }) => {
18560
- const args5 = withRepeatedCopyFlags(parsedArgs, rawArgs);
18443
+ run: async ({ args: args5 }) => {
18561
18444
  const customerId = requireCustomerId(args5);
18562
18445
  const file = loadJsonFileArg(args5.file);
18563
18446
  const format = args5.format;
@@ -18571,8 +18454,7 @@ var adsCommand = defineCommand31({
18571
18454
  await stageUpdate("google.ad.update", customerId, requireTarget(args5, "ad"), payload, [
18572
18455
  ...payload.content !== void 0 ? [
18573
18456
  "Each content field you sent replaces its current value wholesale at publish \u2014 re-check that every headline, description, final URL and asset you want to KEEP is in this payload, not just the ones you changed."
18574
- ] : [],
18575
- ...format ? copyListSplitHints(args5) : []
18457
+ ] : []
18576
18458
  ]);
18577
18459
  }
18578
18460
  }),
@@ -18601,9 +18483,9 @@ var assetGroupsCommand = defineCommand31({
18601
18483
  },
18602
18484
  name: { type: "string", description: "Asset group name" },
18603
18485
  "final-urls": { type: "string", description: "Comma-separated final URLs" },
18604
- headlines: { type: "string", description: `Headlines (3\u201315, \u226430 chars) \u2014 ${AD_COPY_LIST_USAGE}` },
18605
- "long-headlines": { type: "string", description: `Long headlines (1\u20135, \u226490 chars) \u2014 ${AD_COPY_LIST_USAGE}` },
18606
- descriptions: { type: "string", description: `Descriptions (2\u20135, \u226490 chars) \u2014 ${AD_COPY_LIST_USAGE}` },
18486
+ headlines: { type: "string", description: "Comma-separated headlines (3\u201315, \u226430 chars)" },
18487
+ "long-headlines": { type: "string", description: "Comma-separated long headlines (1\u20135, \u226490 chars)" },
18488
+ descriptions: { type: "string", description: "Comma-separated descriptions (2\u20135, \u226490 chars)" },
18607
18489
  "business-name": { type: "string" },
18608
18490
  "image-assets": { type: "string", description: "Comma-separated marketing image asset refs (1.91:1)" },
18609
18491
  "square-image-assets": {
@@ -18617,12 +18499,11 @@ var assetGroupsCommand = defineCommand31({
18617
18499
  "logo-assets": { type: "string", description: "Comma-separated logo image asset refs" },
18618
18500
  status: { type: "string", description: "ENABLED | PAUSED (default PAUSED)" }
18619
18501
  },
18620
- run: async ({ args: parsedArgs, rawArgs }) => {
18621
- const args5 = withRepeatedCopyFlags(parsedArgs, rawArgs);
18502
+ run: async ({ args: args5 }) => {
18622
18503
  const customerId = requireCustomerId(args5);
18623
- const headlines = copyListFlag(args5.headlines, "headlines");
18624
- const longHeadlines = copyListFlag(args5["long-headlines"], "long-headlines");
18625
- const descriptions = copyListFlag(args5.descriptions, "descriptions");
18504
+ const headlines = listFlag(args5.headlines);
18505
+ const longHeadlines = listFlag(args5["long-headlines"]);
18506
+ const descriptions = listFlag(args5.descriptions);
18626
18507
  const payload = mergePayload(loadJsonFileArg(args5.file), {
18627
18508
  campaign: args5["campaign-ref"],
18628
18509
  name: args5.name,
@@ -18637,7 +18518,7 @@ var assetGroupsCommand = defineCommand31({
18637
18518
  logoAssets: listFlag(args5["logo-assets"]),
18638
18519
  status: args5.status
18639
18520
  });
18640
- await stageCreate("google.assetGroup.create", customerId, payload, copyListSplitHints(args5));
18521
+ await stageCreate("google.assetGroup.create", customerId, payload);
18641
18522
  }
18642
18523
  }),
18643
18524
  update: defineCommand31({
@@ -67693,7 +67574,6 @@ function commandFor(root, argv) {
67693
67574
  const { command, resolved } = resolveCommand2(root, argv);
67694
67575
  return resolved ? command : null;
67695
67576
  }
67696
- var OUTPUT_EXPLANATION = "This command has no --output option: `--output json` is accepted by every command that prints the JSON envelope, and md or files only where `baker schema` lists `output`. Drop the option and read the default output. ";
67697
67577
  function unknownFlagEnvelope(unknown, commandPath, suggestion, hasSchema) {
67698
67578
  const list = unknown.join(", ");
67699
67579
  return {
@@ -67703,7 +67583,7 @@ function unknownFlagEnvelope(unknown, commandPath, suggestion, hasSchema) {
67703
67583
  message: `${list} ${unknown.length > 1 ? "are not options" : "is not an option"} of \`baker ${commandPath}\`.`,
67704
67584
  fix: {
67705
67585
  action: hasSchema ? "check_schema" : "check_help",
67706
- explanation: (unknown.some((flag) => flag === "--output" || flag.startsWith("--output=")) ? OUTPUT_EXPLANATION : "") + (suggestion ? `Did you mean ${suggestion}? ` : "") + `Run \`${hasSchema ? `baker schema ${commandPath}` : `baker ${commandPath} --help`}\` to see every option this command takes. Do not re-run the same call: until this version an unrecognised option was accepted and ignored, so a command that looked like it had filtered or narrowed the result was in fact answering the unfiltered question.`
67586
+ explanation: (suggestion ? `Did you mean ${suggestion}? ` : "") + `Run \`${hasSchema ? `baker schema ${commandPath}` : `baker ${commandPath} --help`}\` to see every option this command takes. Do not re-run the same call: until this version an unrecognised option was accepted and ignored, so a command that looked like it had filtered or narrowed the result was in fact answering the unfiltered question.`
67707
67587
  },
67708
67588
  retryable: false
67709
67589
  }
@@ -67742,53 +67622,6 @@ function refuseUnknownFlags(root, argv) {
67742
67622
  process.exit(1);
67743
67623
  }
67744
67624
 
67745
- // src/output-flag.ts
67746
- var FLAG = "--output";
67747
- var ENVELOPE = "json";
67748
- var PRINTS_NO_ENVELOPE = /* @__PURE__ */ new Set(["analytics sending-events", "canvas run", "canvas rerun"]);
67749
- function declaredArg(command, name) {
67750
- const args5 = command.args;
67751
- if (!args5 || typeof args5 !== "object" || !(name in args5)) {
67752
- return null;
67753
- }
67754
- const def = args5[name];
67755
- return def && typeof def === "object" ? def : {};
67756
- }
67757
- function envelopeRequests(argv) {
67758
- const end = argv.indexOf("--");
67759
- const limit = end === -1 ? argv.length : end;
67760
- const found = [];
67761
- for (let index = 0; index < limit; index++) {
67762
- const token = argv[index];
67763
- if (token === `${FLAG}=${ENVELOPE}`) {
67764
- found.push({ index, length: 1 });
67765
- } else if (token === FLAG && argv[index + 1] === ENVELOPE && index + 1 < limit) {
67766
- found.push({ index, length: 2 });
67767
- index++;
67768
- }
67769
- }
67770
- return found;
67771
- }
67772
- function outputFlagForCommand(root, argv) {
67773
- const requests = envelopeRequests(argv);
67774
- if (requests.length === 0) {
67775
- return argv;
67776
- }
67777
- const command = commandFor(root, argv);
67778
- if (!command || declaredArg(command, "output") || PRINTS_NO_ENVELOPE.has(commandPathOf(root, argv))) {
67779
- return argv;
67780
- }
67781
- const jsonSwitch = declaredArg(command, "json")?.type === "boolean";
67782
- const dropped = new Set(requests.flatMap(({ index, length }) => length === 2 ? [index, index + 1] : [index]));
67783
- const first = requests[0]?.index;
67784
- return argv.flatMap((token, index) => {
67785
- if (!dropped.has(index)) {
67786
- return [token];
67787
- }
67788
- return jsonSwitch && index === first ? ["--json"] : [];
67789
- });
67790
- }
67791
-
67792
67625
  // src/version.ts
67793
67626
  import { readFileSync as readFileSync21 } from "fs";
67794
67627
  function packageJsonUrl() {
@@ -67815,7 +67648,7 @@ var main = defineCommand245({
67815
67648
  Auth: Set BAKER_API_KEY (starts with bk_) and BAKER_API_URL environment variables.
67816
67649
  Chat: Set BAKER_CHAT_ID for action and scheduled-action commands that stage changes against a chat.
67817
67650
  Output: All commands return JSON envelopes: { ok: true, data: ... } or { ok: false, error: { code, message } }.
67818
- Formats: --output json works on every command that prints the envelope. --output md|files only where 'baker schema <command>' lists output. (The research commands additionally accept csv and jsonl.)
67651
+ Formats: Use --output json|files|md to control output format. Default: json. (The research commands additionally accept csv and jsonl.)
67819
67652
  Introspection: Run 'baker schema <command>' to inspect argument schemas.`
67820
67653
  },
67821
67654
  subCommands: {
@@ -67853,7 +67686,6 @@ process.argv = [...process.argv.slice(0, 2), ...normalizeCacheFlag(process.argv.
67853
67686
  installStreamTaps();
67854
67687
  logInvocation(process.argv.slice(2));
67855
67688
  installExitRecord();
67856
- process.argv = [...process.argv.slice(0, 2), ...outputFlagForCommand(main, process.argv.slice(2))];
67857
67689
  refuseUnknownFlags(main, process.argv.slice(2));
67858
67690
  process.argv = [...process.argv.slice(0, 2), ...cacheFlagForParser(process.argv.slice(2))];
67859
67691
  runMain(main);