@wirecat/drive-cli 0.52.0 → 0.53.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 (194) hide show
  1. package/README.md +2 -2
  2. package/dist/bin/drive.js +2 -2
  3. package/dist/bin/drive.js.map +1 -1
  4. package/dist/bundle/{chunk-ZWSG7OCA.js → all-profiles-WRN35CUF.js} +11 -6
  5. package/dist/bundle/{anthropic-KW6KU36Y.js → anthropic-DZASXWG3.js} +1 -1
  6. package/dist/bundle/{app-server-TCJZ333E.js → app-server-4VHT7QZN.js} +33 -41
  7. package/dist/bundle/{bun-sqlite-RI7DR6RZ.js → bun-sqlite-2GOM5PM3.js} +1 -1
  8. package/dist/bundle/{chunk-LONV6HIK.js → chunk-2HHOMN2G.js} +440 -25
  9. package/dist/bundle/{chunk-4A2PIGC6.js → chunk-2PVDFLJJ.js} +8 -3
  10. package/dist/bundle/{chunk-725OHXKR.js → chunk-3RYX7IB6.js} +2218 -30
  11. package/dist/bundle/{chunk-CB7SBYLO.js → chunk-54BYJQ77.js} +41 -21
  12. package/dist/bundle/{chunk-5FONRUG6.js → chunk-5D4AEUVA.js} +1 -23
  13. package/dist/bundle/{chunk-RNSP57TC.js → chunk-6BNALDGA.js} +1 -1
  14. package/dist/bundle/{chunk-H47W2J6S.js → chunk-6XYGTRMQ.js} +812 -381
  15. package/dist/bundle/{chunk-UR32UWTQ.js → chunk-7IUMHMTP.js} +11 -0
  16. package/dist/bundle/{chunk-W7IK7E4B.js → chunk-BEL4XZ3M.js} +5 -7
  17. package/dist/bundle/{chunk-43QVYW3K.js → chunk-CL4GVCXS.js} +230 -56
  18. package/dist/bundle/{chunk-PQYVPCJ2.js → chunk-CNKILAWA.js} +18 -24
  19. package/dist/bundle/chunk-DOZOLBXE.js +110 -0
  20. package/dist/bundle/{chunk-2AUXBJRX.js → chunk-DT2YCB2V.js} +84 -11
  21. package/dist/bundle/{chunk-HQVJK5E7.js → chunk-DZMK255Y.js} +210 -357
  22. package/dist/bundle/{chunk-G6QF5KWF.js → chunk-E6XDFMRZ.js} +22 -28
  23. package/dist/bundle/{chunk-DW46P2DY.js → chunk-EKFEY3KP.js} +1 -1
  24. package/dist/bundle/{chunk-54O62JWP.js → chunk-F3KHUJEE.js} +24 -5
  25. package/dist/bundle/{chunk-I7UH5CTA.js → chunk-FXWBUTR7.js} +7 -9
  26. package/dist/bundle/{chunk-ZNZUZGSV.js → chunk-GE4DP24O.js} +131 -4
  27. package/dist/bundle/{chunk-PEOCBV2Z.js → chunk-GPJEYW2J.js} +1 -1
  28. package/dist/bundle/{chunk-A4UNTWAX.js → chunk-HM352LJR.js} +84 -15
  29. package/dist/bundle/{chunk-KYVXMEBC.js → chunk-IAQ4L6SM.js} +1 -1
  30. package/dist/bundle/{chunk-PQJYM5ES.js → chunk-IJFZKQC4.js} +1 -1
  31. package/dist/bundle/{chunk-O6IOL6RX.js → chunk-KPBCGUJC.js} +1 -1
  32. package/dist/bundle/{chunk-XOLQSCMF.js → chunk-KXMJE3XC.js} +2 -2
  33. package/dist/bundle/{chunk-33NVQGUY.js → chunk-LSGAJYVN.js} +2 -2
  34. package/dist/bundle/{chunk-2UIMEMWU.js → chunk-MK3N7WX7.js} +1 -1
  35. package/dist/bundle/{chunk-IDUNJCFO.js → chunk-OQMK6WXQ.js} +1 -1
  36. package/dist/bundle/{chunk-CM7GAXGD.js → chunk-PC4UA6UN.js} +1 -1
  37. package/dist/bundle/{chunk-YNFELLNQ.js → chunk-PIMMF67N.js} +2 -2
  38. package/dist/bundle/{chunk-WBTVGFXI.js → chunk-PR3DA7KA.js} +9 -9
  39. package/dist/bundle/{chunk-VJZST5RD.js → chunk-QXYGK6G5.js} +1 -1
  40. package/dist/bundle/{chunk-WQJBAWQP.js → chunk-R4TE4ZSD.js} +549 -224
  41. package/dist/bundle/{chunk-BSSCTWWK.js → chunk-RNIHKIQP.js} +1 -1
  42. package/dist/bundle/{chunk-PAXKALHV.js → chunk-SIWBUGBU.js} +116 -5
  43. package/dist/bundle/{chunk-2623YE5I.js → chunk-SQHPJBNO.js} +6 -8
  44. package/dist/bundle/chunk-SVTYS36O.js +5305 -0
  45. package/dist/bundle/{chunk-WLFUBNFX.js → chunk-T334CFU4.js} +2 -2
  46. package/dist/bundle/{chunk-UC22Q5KU.js → chunk-TZLO3ZZF.js} +16 -16
  47. package/dist/bundle/{chunk-5PLJKSG4.js → chunk-UFWK3L5Z.js} +4 -6
  48. package/dist/bundle/{chunk-FCJAHD4R.js → chunk-VTWADVEQ.js} +2 -2
  49. package/dist/bundle/{chunk-HX7Y2ASG.js → chunk-WJRJBQIM.js} +26040 -15126
  50. package/dist/bundle/{chunk-VSOLLTYT.js → chunk-YLKQSVLI.js} +5 -0
  51. package/dist/bundle/{chunk-IWFBAWZK.js → chunk-YQOVVCIA.js} +282 -10
  52. package/dist/bundle/{chunk-7YMDL4JQ.js → chunk-ZG6X24ON.js} +4 -1
  53. package/dist/bundle/{command-contract-I2YB5IXI.js → command-contract-D4UG3D33.js} +12 -15
  54. package/dist/bundle/{decode-EDN2ARXZ.js → decode-WAPM2VBH.js} +1 -1
  55. package/dist/bundle/drive.js +10 -21
  56. package/dist/bundle/{embed-3GSQIQXE.js → embed-HW3N3KNP.js} +4 -4
  57. package/dist/bundle/{embedder-6ULWRG3R.js → embedder-7WNFXYYP.js} +4 -4
  58. package/dist/bundle/{entry-IPRJLFHO.js → entry-J7YIRDPD.js} +4 -4
  59. package/dist/bundle/{first-run-FGHGWHC2.js → first-run-53CL2IYH.js} +6 -6
  60. package/dist/bundle/{first-screen-M62KTPZG.js → first-screen-2KT7HM2K.js} +13 -16
  61. package/dist/bundle/{google-BD3ZNFVJ.js → google-5NNVARNR.js} +2 -2
  62. package/dist/bundle/{chunk-GR5GGZKH.js → google-api-EQQH53QD.js} +60 -4
  63. package/dist/bundle/grants-4NETZ4MR.js +98 -0
  64. package/dist/bundle/{identity-QLBSASO5.js → identity-LBTXDMTA.js} +4 -2
  65. package/dist/bundle/{login-VNZKRSAD.js → login-Y6ENYKC3.js} +50 -52
  66. package/dist/bundle/{node-sqlite-J3OODPYK.js → node-sqlite-FSQIKGED.js} +1 -1
  67. package/dist/bundle/{oauth-L4VTCBLF.js → oauth-HF5USWXY.js} +5 -5
  68. package/dist/bundle/{open-SGUN7ZVF.js → open-NHGJENCX.js} +2 -2
  69. package/dist/bundle/{openai-RLVISEDH.js → openai-3JCJYKNX.js} +6 -6
  70. package/dist/bundle/{program-6S5EH7BS.js → program-QAJ66K3Z.js} +715 -904
  71. package/dist/bundle/{prompt-AUWTBLO7.js → prompt-LQJBCCUF.js} +3 -3
  72. package/dist/bundle/{reasons-M5AKCNCU.js → reasons-J57GSRWN.js} +1 -1
  73. package/dist/bundle/{recognize-ORX2UBQW.js → recognize-QM3LN4ZF.js} +1 -1
  74. package/dist/bundle/{remote-AGIJY73X.js → remote-WREGEZJQ.js} +5 -5
  75. package/dist/bundle/{rerank-R6PE44M5.js → rerank-YFUB6J6M.js} +4 -4
  76. package/dist/bundle/{chunk-G7DCVJ4F.js → serve-7NFEZ564.js} +7 -4
  77. package/dist/bundle/{chunk-F7UUZATI.js → server-KBCFZ2AU.js} +38 -11
  78. package/dist/bundle/server-UYVL2CFI.js +63 -0
  79. package/dist/bundle/{services-HZFTTZSF.js → services-C3XWRA2W.js} +16 -21
  80. package/dist/bundle/{sqlite-runtime-DTGPR2T2.js → sqlite-runtime-H3TSAMIN.js} +3 -3
  81. package/dist/bundle/{state-WG3JKJM3.js → state-S2Q53L6L.js} +3 -3
  82. package/dist/bundle/{store-33VHIMEO.js → store-H345VQHP.js} +6 -8
  83. package/dist/bundle/{store-EV72MT5U.js → store-I27LAJPU.js} +7 -9
  84. package/dist/bundle/store-maintenance-command-3XA73XMC.js +52 -0
  85. package/dist/bundle/{chunk-GNI7INK6.js → terminal-DHJ4D3BC.js} +2 -3
  86. package/dist/bundle/tokens-7MUGKFEM.js +96 -0
  87. package/dist/commands/context.d.ts +14 -13
  88. package/dist/commands/context.d.ts.map +1 -1
  89. package/dist/commands/context.js.map +1 -1
  90. package/dist/commands/documents.d.ts.map +1 -1
  91. package/dist/commands/documents.js +1 -4
  92. package/dist/commands/documents.js.map +1 -1
  93. package/dist/commands/mirrors.d.ts.map +1 -1
  94. package/dist/commands/mirrors.js +1 -2
  95. package/dist/commands/mirrors.js.map +1 -1
  96. package/dist/commands/session.d.ts.map +1 -1
  97. package/dist/commands/session.js +2 -1
  98. package/dist/commands/session.js.map +1 -1
  99. package/dist/commands/upgrade.d.ts +1 -1
  100. package/dist/commands/upgrade.d.ts.map +1 -1
  101. package/dist/commands/upgrade.js +4 -9
  102. package/dist/commands/upgrade.js.map +1 -1
  103. package/dist/config.d.ts +182 -0
  104. package/dist/config.d.ts.map +1 -1
  105. package/dist/config.js +38 -3
  106. package/dist/config.js.map +1 -1
  107. package/dist/contract-overrides.d.ts +0 -3
  108. package/dist/contract-overrides.d.ts.map +1 -1
  109. package/dist/contract-overrides.js +0 -234
  110. package/dist/contract-overrides.js.map +1 -1
  111. package/dist/first-screen.d.ts +3 -2
  112. package/dist/first-screen.d.ts.map +1 -1
  113. package/dist/first-screen.js +17 -22
  114. package/dist/first-screen.js.map +1 -1
  115. package/dist/grants.d.ts +9 -0
  116. package/dist/grants.d.ts.map +1 -0
  117. package/dist/grants.js +30 -0
  118. package/dist/grants.js.map +1 -0
  119. package/dist/identity.d.ts.map +1 -1
  120. package/dist/identity.js +2 -0
  121. package/dist/identity.js.map +1 -1
  122. package/dist/login.d.ts.map +1 -1
  123. package/dist/login.js +7 -3
  124. package/dist/login.js.map +1 -1
  125. package/dist/policy-keys.d.ts +12 -0
  126. package/dist/policy-keys.d.ts.map +1 -0
  127. package/dist/policy-keys.js +107 -0
  128. package/dist/policy-keys.js.map +1 -0
  129. package/dist/policy.d.ts +1 -8
  130. package/dist/policy.d.ts.map +1 -1
  131. package/dist/policy.js +2 -105
  132. package/dist/policy.js.map +1 -1
  133. package/dist/program.d.ts +8 -4
  134. package/dist/program.d.ts.map +1 -1
  135. package/dist/program.js +251 -222
  136. package/dist/program.js.map +1 -1
  137. package/dist/reasons.js +1 -1
  138. package/dist/reasons.js.map +1 -1
  139. package/dist/testing/mcp.d.ts +28 -0
  140. package/dist/testing/mcp.d.ts.map +1 -0
  141. package/dist/testing/mcp.js +56 -0
  142. package/dist/testing/mcp.js.map +1 -0
  143. package/dist/tokens.d.ts +0 -2
  144. package/dist/tokens.d.ts.map +1 -1
  145. package/dist/tokens.js +12 -13
  146. package/dist/tokens.js.map +1 -1
  147. package/dist/version.d.ts +1 -1
  148. package/dist/version.js +1 -1
  149. package/package.json +4 -3
  150. package/scenarios/agent-access.md +4 -2
  151. package/dist/bundle/all-profiles-CYW6XBBS.js +0 -26
  152. package/dist/bundle/chunk-234MHU76.js +0 -384
  153. package/dist/bundle/chunk-4CPLOMRK.js +0 -1714
  154. package/dist/bundle/chunk-4Z6TCU5T.js +0 -9
  155. package/dist/bundle/chunk-DO4PDQY5.js +0 -48
  156. package/dist/bundle/chunk-FDWYPONW.js +0 -1988
  157. package/dist/bundle/chunk-FQRJWVEB.js +0 -2
  158. package/dist/bundle/chunk-NPSZPUK6.js +0 -193
  159. package/dist/bundle/chunk-PDGECM5D.js +0 -138
  160. package/dist/bundle/chunk-Q765VPZY.js +0 -421
  161. package/dist/bundle/chunk-WQRGA75U.js +0 -256
  162. package/dist/bundle/chunk-X6ID5EAR.js +0 -522
  163. package/dist/bundle/chunk-YVPHJHIL.js +0 -15572
  164. package/dist/bundle/chunk-Z47LOJUS.js +0 -484
  165. package/dist/bundle/failure-4CVEVY45.js +0 -37
  166. package/dist/bundle/google-api-BDUWZMRV.js +0 -83
  167. package/dist/bundle/mcp-5SNSMI2M.js +0 -502
  168. package/dist/bundle/mcp-JZSYPQA4.js +0 -96
  169. package/dist/bundle/serve-VOBAQHAQ.js +0 -20
  170. package/dist/bundle/server-24PS4M7U.js +0 -70
  171. package/dist/bundle/server-G6HFZ2CK.js +0 -57
  172. package/dist/bundle/store-maintenance-command-ZTUEI4EC.js +0 -58
  173. package/dist/bundle/terminal-TFCTWLOS.js +0 -11
  174. package/dist/bundle/tokens-XDQXUFDQ.js +0 -104
  175. package/dist/commands/doctor.d.ts +0 -56
  176. package/dist/commands/doctor.d.ts.map +0 -1
  177. package/dist/commands/doctor.js +0 -75
  178. package/dist/commands/doctor.js.map +0 -1
  179. package/dist/commands/mcp.d.ts +0 -6
  180. package/dist/commands/mcp.d.ts.map +0 -1
  181. package/dist/commands/mcp.js +0 -156
  182. package/dist/commands/mcp.js.map +0 -1
  183. package/dist/commands/skill.d.ts +0 -6
  184. package/dist/commands/skill.d.ts.map +0 -1
  185. package/dist/commands/skill.js +0 -34
  186. package/dist/commands/skill.js.map +0 -1
  187. package/dist/failure.d.ts +0 -88
  188. package/dist/failure.d.ts.map +0 -1
  189. package/dist/failure.js +0 -60
  190. package/dist/failure.js.map +0 -1
  191. package/dist/mcp.d.ts +0 -175
  192. package/dist/mcp.d.ts.map +0 -1
  193. package/dist/mcp.js +0 -412
  194. package/dist/mcp.js.map +0 -1
@@ -1887,6 +1887,26 @@ var require_cli_table3 = __commonJS({
1887
1887
  }
1888
1888
  });
1889
1889
 
1890
+ // node_modules/.pnpm/@wirecat+cli-base@0.67.0_commander@15.0.0_esbuild@0.28.2_typescript@7.0.2_vitest@5.0.5/node_modules/@wirecat/cli-base/dist/exit-codes.js
1891
+ var EXIT_CODES = {
1892
+ validation_error: 2,
1893
+ configuration_error: 3,
1894
+ authentication_error: 4,
1895
+ permission_error: 5,
1896
+ not_found: 6,
1897
+ confirmation_required: 7,
1898
+ rate_limited: 8,
1899
+ timeout: 9,
1900
+ network_error: 10,
1901
+ provider_error: 11,
1902
+ provider_unavailable: 12,
1903
+ invalid_response: 13,
1904
+ outcome_unknown: 14,
1905
+ cancelled: 130
1906
+ };
1907
+ var exitCodeFor = /* @__PURE__ */ __name((code) => EXIT_CODES[code], "exitCodeFor");
1908
+ var GENERIC_FAILURE = 1;
1909
+
1890
1910
  // node_modules/.pnpm/@wirecat+cli-base@0.67.0_commander@15.0.0_esbuild@0.28.2_typescript@7.0.2_vitest@5.0.5/node_modules/@wirecat/cli-base/dist/sanitize.js
1891
1911
  var CONTROL = (
1892
1912
  // biome-ignore lint/suspicious/noControlCharactersInRegex: matching them is the whole point
@@ -1911,26 +1931,6 @@ var visibleControls = /* @__PURE__ */ __name((text) => {
1911
1931
  }, "visibleControls");
1912
1932
  var singleLine = /* @__PURE__ */ __name((text) => visibleControls(text).replace(LINE_BREAKS, escaped), "singleLine");
1913
1933
 
1914
- // node_modules/.pnpm/@wirecat+cli-base@0.67.0_commander@15.0.0_esbuild@0.28.2_typescript@7.0.2_vitest@5.0.5/node_modules/@wirecat/cli-base/dist/exit-codes.js
1915
- var EXIT_CODES = {
1916
- validation_error: 2,
1917
- configuration_error: 3,
1918
- authentication_error: 4,
1919
- permission_error: 5,
1920
- not_found: 6,
1921
- confirmation_required: 7,
1922
- rate_limited: 8,
1923
- timeout: 9,
1924
- network_error: 10,
1925
- provider_error: 11,
1926
- provider_unavailable: 12,
1927
- invalid_response: 13,
1928
- outcome_unknown: 14,
1929
- cancelled: 130
1930
- };
1931
- var exitCodeFor = /* @__PURE__ */ __name((code) => EXIT_CODES[code], "exitCodeFor");
1932
- var GENERIC_FAILURE = 1;
1933
-
1934
1934
  // node_modules/.pnpm/@wirecat+cli-base@0.67.0_commander@15.0.0_esbuild@0.28.2_typescript@7.0.2_vitest@5.0.5/node_modules/@wirecat/cli-base/dist/failure.js
1935
1935
  var recognise = /* @__PURE__ */ __name((failure) => {
1936
1936
  if (isCliError(failure))
@@ -2078,71 +2078,6 @@ var catchCrashes = /* @__PURE__ */ __name((options) => {
2078
2078
  };
2079
2079
  }, "catchCrashes");
2080
2080
 
2081
- // node_modules/.pnpm/@wirecat+cli-base@0.67.0_commander@15.0.0_esbuild@0.28.2_typescript@7.0.2_vitest@5.0.5/node_modules/@wirecat/cli-base/dist/result-fields.js
2082
- var forbidden = /* @__PURE__ */ new Set(["__proto__", "prototype", "constructor"]);
2083
- var validate = /* @__PURE__ */ __name((paths) => {
2084
- if (paths.length === 0 || paths.length > 128 || paths.some((path) => path.length > 256 || !/^[A-Za-z][A-Za-z0-9_]*(?:\.[A-Za-z][A-Za-z0-9_]*)*$/.test(path) || path.split(".").some((part) => forbidden.has(part))))
2085
- throw new CliError("validation_error", "field selection takes comma-separated field paths, for example id,source.title");
2086
- }, "validate");
2087
- var fieldsOf = /* @__PURE__ */ __name((value) => {
2088
- const paths = value.split(",").map((one) => one.trim());
2089
- validate(paths);
2090
- return [...new Set(paths)];
2091
- }, "fieldsOf");
2092
- var object = /* @__PURE__ */ __name((value) => value !== null && typeof value === "object" && !Array.isArray(value), "object");
2093
- var retained = /* @__PURE__ */ new Set(["operation_id", "page", "next", "missing", "meta", "coverage"]);
2094
- var itemPaths = /* @__PURE__ */ __name((paths) => paths.map((path) => path.startsWith("items.") ? path.slice(6) : path), "itemPaths");
2095
- var onePaths = /* @__PURE__ */ __name((paths) => paths.map((path) => path.startsWith("item.") ? path.slice(5) : path), "onePaths");
2096
- var select = /* @__PURE__ */ __name((value, paths) => {
2097
- if (Array.isArray(value))
2098
- return value.map((item) => select(item, paths));
2099
- if (!object(value))
2100
- return value;
2101
- const result = {};
2102
- const groups = /* @__PURE__ */ new Map();
2103
- for (const path of paths) {
2104
- const [key, ...rest] = path.split(".");
2105
- if (!key)
2106
- continue;
2107
- const children = groups.get(key) ?? [];
2108
- children.push(rest.join("."));
2109
- groups.set(key, children);
2110
- }
2111
- for (const [key, children] of groups) {
2112
- if (!Object.hasOwn(value, key) || value[key] === void 0)
2113
- continue;
2114
- const found = value[key];
2115
- if (children.includes(""))
2116
- result[key] = found;
2117
- else if (object(found) || Array.isArray(found)) {
2118
- const selected = select(found, children);
2119
- if (Array.isArray(selected) || object(selected) && Object.keys(selected).length > 0)
2120
- result[key] = selected;
2121
- }
2122
- }
2123
- for (const key of retained)
2124
- if (Object.hasOwn(value, key))
2125
- result[key] = value[key];
2126
- return result;
2127
- }, "select");
2128
- var project = /* @__PURE__ */ __name((value, fields) => {
2129
- if (Array.isArray(value))
2130
- return value.map((item) => select(item, itemPaths(fields)));
2131
- if (object(value) && Object.hasOwn(value, "type") && value.type === "item" && Object.hasOwn(value, "data") && Object.keys(value).every((key) => ["type", "data"].includes(key)))
2132
- return { ...value, data: project(value.data, fields) };
2133
- if (object(value) && Object.hasOwn(value, "type") && value.type === "end" && Object.hasOwn(value, "complete") && typeof value.complete === "boolean")
2134
- return value;
2135
- if (object(value) && Object.hasOwn(value, "item") && (Object.hasOwn(value, "meta") || Object.keys(value).every((key) => ["item", "next", "missing"].includes(key))))
2136
- return { ...value, item: project(value.item, onePaths(fields)) };
2137
- if (object(value) && Array.isArray(value.items))
2138
- return { ...value, items: value.items.map((item) => select(item, itemPaths(fields))) };
2139
- return select(value, object(value) && !Object.hasOwn(value, "items") ? itemPaths(fields) : fields);
2140
- }, "project");
2141
- var projectFields = /* @__PURE__ */ __name((value, fields) => {
2142
- validate(fields);
2143
- return project(value, fields);
2144
- }, "projectFields");
2145
-
2146
2081
  // node_modules/.pnpm/@wirecat+cli-base@0.67.0_commander@15.0.0_esbuild@0.28.2_typescript@7.0.2_vitest@5.0.5/node_modules/@wirecat/cli-base/dist/keyring.js
2147
2082
  import { createRequire } from "node:module";
2148
2083
  var ENTRY_OPTIONS = { linux: { store: "secret-service" } };
@@ -2389,165 +2324,6 @@ var Credentials = class {
2389
2324
  }
2390
2325
  };
2391
2326
 
2392
- // node_modules/.pnpm/@wirecat+cli-base@0.67.0_commander@15.0.0_esbuild@0.28.2_typescript@7.0.2_vitest@5.0.5/node_modules/@wirecat/cli-base/dist/time.js
2393
- var abortError = /* @__PURE__ */ __name(() => new DOMException("The operation was aborted.", "AbortError"), "abortError");
2394
- var realSleep = /* @__PURE__ */ __name((ms, signal) => new Promise((resolve2, reject) => {
2395
- if (signal?.aborted) {
2396
- reject(abortError());
2397
- return;
2398
- }
2399
- const timer = setTimeout(resolve2, ms);
2400
- signal?.addEventListener("abort", () => {
2401
- clearTimeout(timer);
2402
- reject(abortError());
2403
- }, { once: true });
2404
- }), "realSleep");
2405
-
2406
- // node_modules/.pnpm/@wirecat+cli-base@0.67.0_commander@15.0.0_esbuild@0.28.2_typescript@7.0.2_vitest@5.0.5/node_modules/@wirecat/cli-base/dist/deadline.js
2407
- var createDeadline = /* @__PURE__ */ __name(({ timeoutMs, signal, sleep = realSleep } = {}) => {
2408
- if (timeoutMs !== void 0 && (!Number.isSafeInteger(timeoutMs) || timeoutMs < 0 || timeoutMs > 2147483647))
2409
- throw new CliError("validation_error", "timeoutMs must be an integer from zero through 2147483647");
2410
- const controller = new AbortController();
2411
- const timer = new AbortController();
2412
- let disposed = false;
2413
- const abort = /* @__PURE__ */ __name((reason) => {
2414
- if (controller.signal.aborted)
2415
- return;
2416
- controller.abort(reason);
2417
- timer.abort();
2418
- signal?.removeEventListener("abort", onAbort);
2419
- }, "abort");
2420
- const onAbort = /* @__PURE__ */ __name(() => abort(isCliError(signal?.reason) ? signal.reason : new CliError("cancelled", "command cancelled")), "onAbort");
2421
- if (signal?.aborted)
2422
- onAbort();
2423
- else
2424
- signal?.addEventListener("abort", onAbort, { once: true });
2425
- const expire = /* @__PURE__ */ __name(() => abort(new CliError("timeout", "the command did not finish before its deadline", {
2426
- reason: "command.timed-out",
2427
- timeout_ms: timeoutMs,
2428
- retryable: false
2429
- })), "expire");
2430
- if (timeoutMs === 0)
2431
- expire();
2432
- if (timeoutMs !== void 0 && timeoutMs > 0 && !controller.signal.aborted) {
2433
- let waiting;
2434
- try {
2435
- waiting = sleep(timeoutMs, timer.signal, "timeout");
2436
- } catch {
2437
- waiting = Promise.reject(new Error("deadline timer failed"));
2438
- }
2439
- void waiting.then(() => {
2440
- if (!disposed && !timer.signal.aborted)
2441
- expire();
2442
- }, () => {
2443
- if (!disposed && !timer.signal.aborted)
2444
- abort(new CliError("configuration_error", "command deadline timer failed"));
2445
- });
2446
- }
2447
- return {
2448
- signal: controller.signal,
2449
- async race(body) {
2450
- if (disposed)
2451
- throw new CliError("validation_error", "deadline is already disposed");
2452
- if (controller.signal.aborted)
2453
- throw controller.signal.reason;
2454
- let interrupt = /* @__PURE__ */ __name(() => {
2455
- }, "interrupt");
2456
- const interrupted = new Promise((_, reject) => {
2457
- interrupt = /* @__PURE__ */ __name(() => reject(controller.signal.reason), "interrupt");
2458
- controller.signal.addEventListener("abort", interrupt, { once: true });
2459
- });
2460
- const running = Promise.resolve().then(() => {
2461
- if (controller.signal.aborted)
2462
- throw controller.signal.reason;
2463
- return body(controller.signal);
2464
- });
2465
- try {
2466
- return await Promise.race([running, interrupted]);
2467
- } catch (error) {
2468
- if (controller.signal.aborted) {
2469
- let settled;
2470
- await running.catch((reason) => {
2471
- settled = reason;
2472
- });
2473
- if (isCliError(settled) && settled.code === "outcome_unknown")
2474
- throw settled;
2475
- throw controller.signal.reason;
2476
- }
2477
- throw error;
2478
- } finally {
2479
- controller.signal.removeEventListener("abort", interrupt);
2480
- }
2481
- },
2482
- dispose() {
2483
- disposed = true;
2484
- timer.abort();
2485
- signal?.removeEventListener("abort", onAbort);
2486
- }
2487
- };
2488
- }, "createDeadline");
2489
-
2490
- // node_modules/.pnpm/@wirecat+cli-base@0.67.0_commander@15.0.0_esbuild@0.28.2_typescript@7.0.2_vitest@5.0.5/node_modules/@wirecat/cli-base/dist/output-buffer.js
2491
- var createOutputBuffer = /* @__PURE__ */ __name(({ maxOutputBytes = 4 * 1024 * 1024, fields, format } = {}) => {
2492
- if (!Number.isSafeInteger(maxOutputBytes) || maxOutputBytes < 0)
2493
- throw new CliError("validation_error", "maxOutputBytes must be a nonnegative whole byte count");
2494
- const paths = fields === void 0 ? void 0 : fieldsOf(fields);
2495
- if (paths && format !== "json" && format !== "jsonl")
2496
- throw new CliError("validation_error", "field projection requires an explicit JSON or JSONL format");
2497
- let chunks = [];
2498
- let bytes = 0;
2499
- let finished = false;
2500
- const requireActive = /* @__PURE__ */ __name(() => {
2501
- if (finished)
2502
- throw new CliError("validation_error", "output buffer is already finished");
2503
- }, "requireActive");
2504
- return {
2505
- get bytes() {
2506
- return bytes;
2507
- },
2508
- data(text) {
2509
- requireActive();
2510
- let result = text;
2511
- if (paths) {
2512
- const project2 = /* @__PURE__ */ __name((value) => JSON.stringify(projectFields(JSON.parse(value), paths)), "project");
2513
- try {
2514
- result = format === "jsonl" ? text.split("\n").map((line) => line.trim() ? project2(line) : line).join("\n") : project2(text) + (text.endsWith("\n") ? "\n" : "");
2515
- } catch (error) {
2516
- if (isCliError(error))
2517
- throw error;
2518
- throw new CliError("invalid_response", "field projection requires complete JSON values or JSONL lines", {
2519
- reason: "output.fields-unavailable",
2520
- retryable: false
2521
- });
2522
- }
2523
- }
2524
- const size = Buffer.byteLength(result);
2525
- if (!Number.isSafeInteger(bytes + size) || maxOutputBytes !== 0 && bytes + size > maxOutputBytes)
2526
- throw new CliError("invalid_response", "output exceeds the configured byte limit", {
2527
- reason: "output.too-large",
2528
- max_bytes: maxOutputBytes,
2529
- buffered_bytes: bytes,
2530
- retryable: false,
2531
- partial_output: false
2532
- });
2533
- bytes += size;
2534
- chunks.push(result);
2535
- },
2536
- flush(write) {
2537
- requireActive();
2538
- finished = true;
2539
- const output = chunks;
2540
- chunks = [];
2541
- for (const text of output)
2542
- write(text);
2543
- },
2544
- discard() {
2545
- finished = true;
2546
- chunks = [];
2547
- }
2548
- };
2549
- }, "createOutputBuffer");
2550
-
2551
2327
  // node_modules/.pnpm/@wirecat+cli-base@0.67.0_commander@15.0.0_esbuild@0.28.2_typescript@7.0.2_vitest@5.0.5/node_modules/@wirecat/cli-base/dist/drain.js
2552
2328
  var waitForDrain = /* @__PURE__ */ __name((stream, signal) => {
2553
2329
  if (signal?.aborted)
@@ -2605,117 +2381,6 @@ var captureStreams = /* @__PURE__ */ __name(() => {
2605
2381
  };
2606
2382
  }, "captureStreams");
2607
2383
 
2608
- // node_modules/.pnpm/@wirecat+cli-base@0.67.0_commander@15.0.0_esbuild@0.28.2_typescript@7.0.2_vitest@5.0.5/node_modules/@wirecat/cli-base/dist/pretty.js
2609
- var import_cli_table3 = __toESM(require_cli_table3(), 1);
2610
- import { styleText } from "node:util";
2611
- var renderPretty = /* @__PURE__ */ __name((value, options) => {
2612
- const paint2 = palette(options.color);
2613
- if (Array.isArray(value)) {
2614
- if (value.length === 0)
2615
- return paint2.dim("(nothing)");
2616
- return isRowLike(value) ? renderTable(value, paint2) : renderJson(value);
2617
- }
2618
- if (isPlainObject(value)) {
2619
- const listKey = Object.keys(value).find((key) => Array.isArray(value[key]) && isRowLike(value[key]));
2620
- if (listKey) {
2621
- const rest = Object.fromEntries(Object.entries(value).filter(([key]) => key !== listKey));
2622
- const table = renderTable(value[listKey], paint2);
2623
- return Object.keys(rest).length > 0 ? `${table}
2624
-
2625
- ${renderFields(rest, paint2)}` : table;
2626
- }
2627
- return renderFields(value, paint2);
2628
- }
2629
- return renderJson(value);
2630
- }, "renderPretty");
2631
- var paint = /* @__PURE__ */ __name((format, color) => (text) => color ? styleText(format, text, { validateStream: false }) : text, "paint");
2632
- var palette = /* @__PURE__ */ __name((color) => ({
2633
- dim: paint("dim", color),
2634
- bold: paint("bold", color),
2635
- label: paint("cyan", color)
2636
- }), "palette");
2637
- var isPlainObject = /* @__PURE__ */ __name((value) => typeof value === "object" && value !== null && !Array.isArray(value), "isPlainObject");
2638
- var isRowLike = /* @__PURE__ */ __name((value) => value.length > 0 && value.every((item) => isPlainObject(item)) && value.length <= 500, "isRowLike");
2639
- var renderTable = /* @__PURE__ */ __name((rows, paint2) => {
2640
- const columns = [...new Set(rows.flatMap((row) => Object.keys(row)))];
2641
- const table = new import_cli_table3.default({
2642
- head: columns.map((column) => paint2.bold(visibleControls(column))),
2643
- // `chars: {}` is not enough — cli-table3 falls back to its own defaults for anything unset.
2644
- style: { head: [], border: [], "padding-left": 0, "padding-right": 2 },
2645
- chars: BORDERLESS
2646
- });
2647
- for (const row of rows)
2648
- table.push(columns.map((column) => cell(row[column])));
2649
- return table.toString();
2650
- }, "renderTable");
2651
- var renderFields = /* @__PURE__ */ __name((fields, paint2) => {
2652
- const rows = Object.entries(fields).map(([key, value]) => ({ label: visibleControls(key), value }));
2653
- const width = Math.max(...rows.map((row) => row.label.length));
2654
- return rows.map((row) => `${paint2.label(row.label.padEnd(width))} ${cell(row.value)}`).join("\n");
2655
- }, "renderFields");
2656
- var cell = /* @__PURE__ */ __name((value) => {
2657
- if (value === null || value === void 0)
2658
- return "";
2659
- if (typeof value === "object")
2660
- return visibleControls(JSON.stringify(value));
2661
- return visibleControls(String(value));
2662
- }, "cell");
2663
- var renderJson = /* @__PURE__ */ __name((value) => JSON.stringify(value, null, 2), "renderJson");
2664
- var BORDERLESS = {
2665
- top: "",
2666
- "top-mid": "",
2667
- "top-left": "",
2668
- "top-right": "",
2669
- bottom: "",
2670
- "bottom-mid": "",
2671
- "bottom-left": "",
2672
- "bottom-right": "",
2673
- left: "",
2674
- "left-mid": "",
2675
- mid: "",
2676
- "mid-mid": "",
2677
- right: "",
2678
- "right-mid": "",
2679
- middle: ""
2680
- };
2681
-
2682
- // node_modules/.pnpm/@wirecat+cli-base@0.67.0_commander@15.0.0_esbuild@0.28.2_typescript@7.0.2_vitest@5.0.5/node_modules/@wirecat/cli-base/dist/renderer.js
2683
- var createRenderer = /* @__PURE__ */ __name(({ format, color, streams = processStreams, quiet = false }) => {
2684
- const mark = /* @__PURE__ */ __name((symbol, message) => format === "pretty" ? `${symbol} ${visibleControls(message)}` : visibleControls(message), "mark");
2685
- const say = /* @__PURE__ */ __name((symbol) => (message) => {
2686
- if (!quiet)
2687
- streams.diagnostic(mark(symbol, message));
2688
- }, "say");
2689
- const diagnostics = {
2690
- note: say("\xB7"),
2691
- success: say("\u2713"),
2692
- warn: say("!"),
2693
- failure: /* @__PURE__ */ __name((message) => streams.diagnostic(mark("\u2717", message)), "failure")
2694
- };
2695
- if (format === "jsonl") {
2696
- return {
2697
- ...diagnostics,
2698
- result: /* @__PURE__ */ __name((value) => streams.data(JSON.stringify(value)), "result"),
2699
- stream: /* @__PURE__ */ __name((items) => {
2700
- for (const item of items)
2701
- streams.data(JSON.stringify(item));
2702
- }, "stream")
2703
- };
2704
- }
2705
- if (format === "pretty") {
2706
- return {
2707
- ...diagnostics,
2708
- result: /* @__PURE__ */ __name((value) => streams.data(renderPretty(value, { color })), "result"),
2709
- stream: /* @__PURE__ */ __name((items) => streams.data(renderPretty([...items], { color })), "stream")
2710
- };
2711
- }
2712
- return {
2713
- ...diagnostics,
2714
- result: /* @__PURE__ */ __name((value) => streams.data(JSON.stringify(value)), "result"),
2715
- stream: /* @__PURE__ */ __name((items) => streams.data(JSON.stringify([...items])), "stream")
2716
- };
2717
- }, "createRenderer");
2718
-
2719
2384
  // node_modules/.pnpm/@wirecat+cli-base@0.67.0_commander@15.0.0_esbuild@0.28.2_typescript@7.0.2_vitest@5.0.5/node_modules/@wirecat/cli-base/dist/retry.js
2720
2385
  var DEFAULT_RETRY = {
2721
2386
  retries: 1,
@@ -2728,6 +2393,71 @@ var backoffMs = /* @__PURE__ */ __name((attempt, config, random) => {
2728
2393
  return Math.round(random() * ceiling);
2729
2394
  }, "backoffMs");
2730
2395
 
2396
+ // node_modules/.pnpm/@wirecat+cli-base@0.67.0_commander@15.0.0_esbuild@0.28.2_typescript@7.0.2_vitest@5.0.5/node_modules/@wirecat/cli-base/dist/result-fields.js
2397
+ var forbidden = /* @__PURE__ */ new Set(["__proto__", "prototype", "constructor"]);
2398
+ var validate = /* @__PURE__ */ __name((paths) => {
2399
+ if (paths.length === 0 || paths.length > 128 || paths.some((path) => path.length > 256 || !/^[A-Za-z][A-Za-z0-9_]*(?:\.[A-Za-z][A-Za-z0-9_]*)*$/.test(path) || path.split(".").some((part) => forbidden.has(part))))
2400
+ throw new CliError("validation_error", "field selection takes comma-separated field paths, for example id,source.title");
2401
+ }, "validate");
2402
+ var fieldsOf = /* @__PURE__ */ __name((value) => {
2403
+ const paths = value.split(",").map((one) => one.trim());
2404
+ validate(paths);
2405
+ return [...new Set(paths)];
2406
+ }, "fieldsOf");
2407
+ var object = /* @__PURE__ */ __name((value) => value !== null && typeof value === "object" && !Array.isArray(value), "object");
2408
+ var retained = /* @__PURE__ */ new Set(["operation_id", "page", "next", "missing", "meta", "coverage"]);
2409
+ var itemPaths = /* @__PURE__ */ __name((paths) => paths.map((path) => path.startsWith("items.") ? path.slice(6) : path), "itemPaths");
2410
+ var onePaths = /* @__PURE__ */ __name((paths) => paths.map((path) => path.startsWith("item.") ? path.slice(5) : path), "onePaths");
2411
+ var select = /* @__PURE__ */ __name((value, paths) => {
2412
+ if (Array.isArray(value))
2413
+ return value.map((item) => select(item, paths));
2414
+ if (!object(value))
2415
+ return value;
2416
+ const result = {};
2417
+ const groups = /* @__PURE__ */ new Map();
2418
+ for (const path of paths) {
2419
+ const [key, ...rest] = path.split(".");
2420
+ if (!key)
2421
+ continue;
2422
+ const children = groups.get(key) ?? [];
2423
+ children.push(rest.join("."));
2424
+ groups.set(key, children);
2425
+ }
2426
+ for (const [key, children] of groups) {
2427
+ if (!Object.hasOwn(value, key) || value[key] === void 0)
2428
+ continue;
2429
+ const found = value[key];
2430
+ if (children.includes(""))
2431
+ result[key] = found;
2432
+ else if (object(found) || Array.isArray(found)) {
2433
+ const selected = select(found, children);
2434
+ if (Array.isArray(selected) || object(selected) && Object.keys(selected).length > 0)
2435
+ result[key] = selected;
2436
+ }
2437
+ }
2438
+ for (const key of retained)
2439
+ if (Object.hasOwn(value, key))
2440
+ result[key] = value[key];
2441
+ return result;
2442
+ }, "select");
2443
+ var project = /* @__PURE__ */ __name((value, fields) => {
2444
+ if (Array.isArray(value))
2445
+ return value.map((item) => select(item, itemPaths(fields)));
2446
+ if (object(value) && Object.hasOwn(value, "type") && value.type === "item" && Object.hasOwn(value, "data") && Object.keys(value).every((key) => ["type", "data"].includes(key)))
2447
+ return { ...value, data: project(value.data, fields) };
2448
+ if (object(value) && Object.hasOwn(value, "type") && value.type === "end" && Object.hasOwn(value, "complete") && typeof value.complete === "boolean")
2449
+ return value;
2450
+ if (object(value) && Object.hasOwn(value, "item") && (Object.hasOwn(value, "meta") || Object.keys(value).every((key) => ["item", "next", "missing"].includes(key))))
2451
+ return { ...value, item: project(value.item, onePaths(fields)) };
2452
+ if (object(value) && Array.isArray(value.items))
2453
+ return { ...value, items: value.items.map((item) => select(item, itemPaths(fields))) };
2454
+ return select(value, object(value) && !Object.hasOwn(value, "items") ? itemPaths(fields) : fields);
2455
+ }, "project");
2456
+ var projectFields = /* @__PURE__ */ __name((value, fields) => {
2457
+ validate(fields);
2458
+ return project(value, fields);
2459
+ }, "projectFields");
2460
+
2731
2461
  // node_modules/.pnpm/@wirecat+cli-base@0.67.0_commander@15.0.0_esbuild@0.28.2_typescript@7.0.2_vitest@5.0.5/node_modules/@wirecat/cli-base/dist/batch.js
2732
2462
  var BATCH_LIMITS = Object.freeze({
2733
2463
  requests: 32,
@@ -2855,6 +2585,20 @@ var runBatch = /* @__PURE__ */ __name(async (requests, options = {}) => {
2855
2585
  };
2856
2586
  }, "runBatch");
2857
2587
 
2588
+ // node_modules/.pnpm/@wirecat+cli-base@0.67.0_commander@15.0.0_esbuild@0.28.2_typescript@7.0.2_vitest@5.0.5/node_modules/@wirecat/cli-base/dist/time.js
2589
+ var abortError = /* @__PURE__ */ __name(() => new DOMException("The operation was aborted.", "AbortError"), "abortError");
2590
+ var realSleep = /* @__PURE__ */ __name((ms, signal) => new Promise((resolve2, reject) => {
2591
+ if (signal?.aborted) {
2592
+ reject(abortError());
2593
+ return;
2594
+ }
2595
+ const timer = setTimeout(resolve2, ms);
2596
+ signal?.addEventListener("abort", () => {
2597
+ clearTimeout(timer);
2598
+ reject(abortError());
2599
+ }, { once: true });
2600
+ }), "realSleep");
2601
+
2858
2602
  // node_modules/.pnpm/@wirecat+cli-base@0.67.0_commander@15.0.0_esbuild@0.28.2_typescript@7.0.2_vitest@5.0.5/node_modules/@wirecat/cli-base/dist/logging.js
2859
2603
  import { appendFileSync } from "node:fs";
2860
2604
  var REDACTED_FIELDS = [
@@ -2950,6 +2694,117 @@ var silent = {
2950
2694
  }, "error")
2951
2695
  };
2952
2696
 
2697
+ // node_modules/.pnpm/@wirecat+cli-base@0.67.0_commander@15.0.0_esbuild@0.28.2_typescript@7.0.2_vitest@5.0.5/node_modules/@wirecat/cli-base/dist/pretty.js
2698
+ var import_cli_table3 = __toESM(require_cli_table3(), 1);
2699
+ import { styleText } from "node:util";
2700
+ var renderPretty = /* @__PURE__ */ __name((value, options) => {
2701
+ const paint2 = palette(options.color);
2702
+ if (Array.isArray(value)) {
2703
+ if (value.length === 0)
2704
+ return paint2.dim("(nothing)");
2705
+ return isRowLike(value) ? renderTable(value, paint2) : renderJson(value);
2706
+ }
2707
+ if (isPlainObject(value)) {
2708
+ const listKey = Object.keys(value).find((key) => Array.isArray(value[key]) && isRowLike(value[key]));
2709
+ if (listKey) {
2710
+ const rest = Object.fromEntries(Object.entries(value).filter(([key]) => key !== listKey));
2711
+ const table = renderTable(value[listKey], paint2);
2712
+ return Object.keys(rest).length > 0 ? `${table}
2713
+
2714
+ ${renderFields(rest, paint2)}` : table;
2715
+ }
2716
+ return renderFields(value, paint2);
2717
+ }
2718
+ return renderJson(value);
2719
+ }, "renderPretty");
2720
+ var paint = /* @__PURE__ */ __name((format, color) => (text) => color ? styleText(format, text, { validateStream: false }) : text, "paint");
2721
+ var palette = /* @__PURE__ */ __name((color) => ({
2722
+ dim: paint("dim", color),
2723
+ bold: paint("bold", color),
2724
+ label: paint("cyan", color)
2725
+ }), "palette");
2726
+ var isPlainObject = /* @__PURE__ */ __name((value) => typeof value === "object" && value !== null && !Array.isArray(value), "isPlainObject");
2727
+ var isRowLike = /* @__PURE__ */ __name((value) => value.length > 0 && value.every((item) => isPlainObject(item)) && value.length <= 500, "isRowLike");
2728
+ var renderTable = /* @__PURE__ */ __name((rows, paint2) => {
2729
+ const columns = [...new Set(rows.flatMap((row) => Object.keys(row)))];
2730
+ const table = new import_cli_table3.default({
2731
+ head: columns.map((column) => paint2.bold(visibleControls(column))),
2732
+ // `chars: {}` is not enough — cli-table3 falls back to its own defaults for anything unset.
2733
+ style: { head: [], border: [], "padding-left": 0, "padding-right": 2 },
2734
+ chars: BORDERLESS
2735
+ });
2736
+ for (const row of rows)
2737
+ table.push(columns.map((column) => cell(row[column])));
2738
+ return table.toString();
2739
+ }, "renderTable");
2740
+ var renderFields = /* @__PURE__ */ __name((fields, paint2) => {
2741
+ const rows = Object.entries(fields).map(([key, value]) => ({ label: visibleControls(key), value }));
2742
+ const width = Math.max(...rows.map((row) => row.label.length));
2743
+ return rows.map((row) => `${paint2.label(row.label.padEnd(width))} ${cell(row.value)}`).join("\n");
2744
+ }, "renderFields");
2745
+ var cell = /* @__PURE__ */ __name((value) => {
2746
+ if (value === null || value === void 0)
2747
+ return "";
2748
+ if (typeof value === "object")
2749
+ return visibleControls(JSON.stringify(value));
2750
+ return visibleControls(String(value));
2751
+ }, "cell");
2752
+ var renderJson = /* @__PURE__ */ __name((value) => JSON.stringify(value, null, 2), "renderJson");
2753
+ var BORDERLESS = {
2754
+ top: "",
2755
+ "top-mid": "",
2756
+ "top-left": "",
2757
+ "top-right": "",
2758
+ bottom: "",
2759
+ "bottom-mid": "",
2760
+ "bottom-left": "",
2761
+ "bottom-right": "",
2762
+ left: "",
2763
+ "left-mid": "",
2764
+ mid: "",
2765
+ "mid-mid": "",
2766
+ right: "",
2767
+ "right-mid": "",
2768
+ middle: ""
2769
+ };
2770
+
2771
+ // node_modules/.pnpm/@wirecat+cli-base@0.67.0_commander@15.0.0_esbuild@0.28.2_typescript@7.0.2_vitest@5.0.5/node_modules/@wirecat/cli-base/dist/renderer.js
2772
+ var createRenderer = /* @__PURE__ */ __name(({ format, color, streams = processStreams, quiet = false }) => {
2773
+ const mark = /* @__PURE__ */ __name((symbol, message) => format === "pretty" ? `${symbol} ${visibleControls(message)}` : visibleControls(message), "mark");
2774
+ const say = /* @__PURE__ */ __name((symbol) => (message) => {
2775
+ if (!quiet)
2776
+ streams.diagnostic(mark(symbol, message));
2777
+ }, "say");
2778
+ const diagnostics = {
2779
+ note: say("\xB7"),
2780
+ success: say("\u2713"),
2781
+ warn: say("!"),
2782
+ failure: /* @__PURE__ */ __name((message) => streams.diagnostic(mark("\u2717", message)), "failure")
2783
+ };
2784
+ if (format === "jsonl") {
2785
+ return {
2786
+ ...diagnostics,
2787
+ result: /* @__PURE__ */ __name((value) => streams.data(JSON.stringify(value)), "result"),
2788
+ stream: /* @__PURE__ */ __name((items) => {
2789
+ for (const item of items)
2790
+ streams.data(JSON.stringify(item));
2791
+ }, "stream")
2792
+ };
2793
+ }
2794
+ if (format === "pretty") {
2795
+ return {
2796
+ ...diagnostics,
2797
+ result: /* @__PURE__ */ __name((value) => streams.data(renderPretty(value, { color })), "result"),
2798
+ stream: /* @__PURE__ */ __name((items) => streams.data(renderPretty([...items], { color })), "stream")
2799
+ };
2800
+ }
2801
+ return {
2802
+ ...diagnostics,
2803
+ result: /* @__PURE__ */ __name((value) => streams.data(JSON.stringify(value)), "result"),
2804
+ stream: /* @__PURE__ */ __name((items) => streams.data(JSON.stringify([...items])), "stream")
2805
+ };
2806
+ }, "createRenderer");
2807
+
2953
2808
  export {
2954
2809
  EXIT_CODES,
2955
2810
  exitCodeFor,
@@ -2979,10 +2834,8 @@ export {
2979
2834
  keyringService,
2980
2835
  Credentials,
2981
2836
  realSleep,
2982
- createDeadline,
2983
2837
  logRecordOf,
2984
2838
  createRecordLog,
2985
- createOutputBuffer,
2986
2839
  processStreams,
2987
2840
  captureStreams,
2988
2841
  createRenderer,