void 0.10.13 → 0.20.1

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 (432) hide show
  1. package/AGENTS_TEMPLATE.md +6 -0
  2. package/{skills/void/docs/node_modules/void/node_modules/pglite-server/LICENSE.md → LICENSE} +1 -1
  3. package/README.md +34 -8
  4. package/dist/{auth-qgMlYp7Z.d.mts → auth-DkcFflXV.d.mts} +10 -11
  5. package/dist/auth-W9WII-mN.mjs +630 -0
  6. package/dist/{auth-cmd-BqsdZJp5.mjs → auth-cmd-CAH62yDU.mjs} +4 -3
  7. package/dist/{auth-migrations-BTZ-ATvQ.mjs → auth-migrations-9vif1uj8.mjs} +53 -12
  8. package/dist/{better-auth-shared-BQooDxbw.mjs → better-auth-shared-CYw1T3k4.mjs} +7 -10
  9. package/dist/{better-auth-shared-DealXecJ.d.mts → better-auth-shared-DSCeohOK.d.mts} +10 -5
  10. package/dist/{build-cmd-Bujrv5q-.mjs → build-cmd-CJvZvPQO.mjs} +6 -4
  11. package/dist/{cache-C11V8Fxq.mjs → cache-BlNeQjuP.mjs} +9 -5
  12. package/dist/{cancel-deploy-fwFYF04b.mjs → cancel-deploy-CmlAZ9P6.mjs} +3 -2
  13. package/dist/cf-access-AJ1ehiFR.mjs +42 -0
  14. package/dist/cf-access-DsSsZUPr.mjs +67 -0
  15. package/dist/cli/cli.d.mts +1 -1
  16. package/dist/cli/cli.mjs +1735 -165
  17. package/dist/cli/env-schema-probe.d.mts +48 -61
  18. package/dist/cli/env-schema-probe.mjs +10 -58
  19. package/dist/{client-Gb71-XkG.mjs → client-Clirrol3.mjs} +120 -463
  20. package/dist/cloudflare-auth-B1QtTO1b.mjs +217 -0
  21. package/dist/cloudflare-cmd-B6_OZx2V.mjs +62 -0
  22. package/dist/cloudflare-connect-j5D4hhrG.mjs +56 -0
  23. package/dist/cloudflare-operations-CPTpRW6d.mjs +566 -0
  24. package/dist/{config-qHGgPuWT.mjs → config-BQFq7QvD.mjs} +75 -41
  25. package/dist/{config-CutEMNGJ.mjs → config-NOG_U1aK.mjs} +10 -15
  26. package/dist/connect-C04Wdy_h.mjs +79 -0
  27. package/dist/{create-project-DsYvl3TB.mjs → create-project-ChGZ1DFd.mjs} +26 -16
  28. package/dist/database-provider.d.mts +21 -0
  29. package/dist/database-provider.mjs +6 -0
  30. package/dist/{db-C0i0sYMS.mjs → db-D2d_mUsB.mjs} +612 -117
  31. package/dist/{delete-mh6p-zkQ.mjs → delete-D8GigDk8.mjs} +9 -6
  32. package/dist/{deploy-jBJT1fUT.mjs → deploy-iXZ3F0N6.mjs} +3252 -1995
  33. package/dist/dev-inbox-DkgRWLkW.mjs +307 -0
  34. package/dist/{discover-CJHyvYfR.mjs → discover-xvfrgJeo.mjs} +3 -3
  35. package/dist/{magic-string.es-ZQjdJFFn.mjs → dist-BR1quN_w.mjs} +570 -216
  36. package/dist/{dist-DaKKDf8D.mjs → dist-BrsS7cai.mjs} +17 -2
  37. package/dist/{dist-BuiRJkTd.mjs → dist-m40_XgNh.mjs} +48 -33
  38. package/dist/{domain-DiaNQbrl.mjs → domain-B1VmoSr0.mjs} +41 -4
  39. package/dist/dotenv-VQxupEUv.mjs +181 -0
  40. package/dist/edge.d.mts +2 -0
  41. package/dist/edge.mjs +2 -0
  42. package/dist/email-Ce6SQq-i.mjs +182 -0
  43. package/dist/email-uKyQYUVY.mjs +1016 -0
  44. package/dist/{entry-D7yy4xVH.mjs → entry-DU3oDoQ3.mjs} +2 -2
  45. package/dist/env-BcQzYgoG.mjs +73 -0
  46. package/dist/env-D4Emu-M_.mjs +95 -0
  47. package/dist/env-helpers-CyKtOBpj.d.mts +22 -0
  48. package/dist/env-public-D_6u46fX.d.mts +135 -0
  49. package/dist/{env-types-QBj-ndax.mjs → env-types-BNPhro-M.mjs} +2 -2
  50. package/dist/{env-validation-Dea3v3ej.mjs → env-validation-ENpMy6Ez.mjs} +68 -122
  51. package/dist/{gen-BzXf3Jh2.mjs → gen-DI2YwdBM.mjs} +70 -15
  52. package/dist/generate-RTK8_kK1.mjs +47 -0
  53. package/dist/{github-cmd-DKcGUNsj.mjs → github-cmd-xItS5Zwf.mjs} +39 -31
  54. package/dist/{handler-Cjh8uM3Y.d.mts → handler-D1hLsObx.d.mts} +124 -122
  55. package/dist/{head-nmvOgFjd.d.mts → head-Do8P4puT.d.mts} +9 -8
  56. package/dist/{headers-ChAADPQu.mjs → headers-D8QfRX9Y.mjs} +12 -10
  57. package/dist/inbound-2d0zi2yS.mjs +706 -0
  58. package/dist/inbound-afAcWeQ9.d.mts +363 -0
  59. package/dist/index.d.mts +61 -34
  60. package/dist/index.mjs +1012 -293
  61. package/dist/{init-7JCAcKNQ.mjs → init-BD-9THgn.mjs} +329 -271
  62. package/dist/link-RMdgjF1v.mjs +52 -0
  63. package/dist/{list-CPwFDZ_c.mjs → list-3F52R_yO.mjs} +37 -5
  64. package/dist/{runner-kapo9aPs.mjs → local-d1-D2I6Ox5F.mjs} +116 -6
  65. package/dist/{login-BT3H8PN3.mjs → login-pV69H-ZO.mjs} +17 -15
  66. package/dist/{logs-Bt313ax7.mjs → logs-DFHHD6wE.mjs} +16 -2
  67. package/dist/mime-BJD7d_qL.mjs +1216 -0
  68. package/dist/neon-DHwd2zvC.mjs +54 -0
  69. package/dist/{node-pRg81HqV.mjs → node-Dk3H2jmU.mjs} +29 -8
  70. package/dist/operator-cmd-DYWRbWUA.mjs +348 -0
  71. package/dist/{agents-CtgBYqld.mjs → output-tFQLLj26.mjs} +676 -211
  72. package/dist/{package-json-Cx1osYo6.mjs → package-json-CPoWX79C.mjs} +1 -1
  73. package/dist/pages/client.d.mts +43 -41
  74. package/dist/pages/client.mjs +40 -33
  75. package/dist/pages/head-client.d.mts +10 -12
  76. package/dist/pages/head.d.mts +1 -1
  77. package/dist/pages/index.d.mts +37 -14
  78. package/dist/pages/index.mjs +5 -5
  79. package/dist/pages/islands-plugin.d.mts +25 -27
  80. package/dist/pages/islands-plugin.mjs +6 -4
  81. package/dist/pages/prefetch.d.mts +6 -7
  82. package/dist/pages/protocol.d.mts +2 -2
  83. package/dist/pages/protocol.mjs +2 -1
  84. package/dist/pages/serialize.d.mts +7 -8
  85. package/dist/platform-cmd-DxJ2FRwR.mjs +123 -0
  86. package/dist/platform-domain-ChvbJkdy.mjs +228 -0
  87. package/dist/platform-lifecycle-DN4MzJF_.mjs +4450 -0
  88. package/dist/platform-management-Db2PXw0B.mjs +698 -0
  89. package/dist/platform-recovery-C_YO-tIs.mjs +99 -0
  90. package/dist/{plugin-inference-DMeavIJ6.mjs → plugin-inference-BDRfZngg.mjs} +35 -19
  91. package/dist/prepare-BfJvFUtJ.mjs +14 -0
  92. package/dist/{prepare-BvvgAz-3.mjs → prepare-CBetXvsN.mjs} +15 -24
  93. package/dist/{preset-BjyR3lzz.mjs → preset-lAy0B0BQ.mjs} +25 -212
  94. package/dist/{project-cmd-D_w-4w5B.mjs → project-cmd-Mo0V9yKS.mjs} +25 -12
  95. package/dist/{project-paths-BQd7OmIo.mjs → project-paths-SK8nMHPp.mjs} +3 -1
  96. package/dist/{project-tsconfig-B-QtXjLQ.mjs → project-tsconfig-Ql2XsSQp.mjs} +2 -2
  97. package/dist/{protocol-Bnb0LFp3.d.mts → protocol-C-pqYJjE.d.mts} +3 -4
  98. package/dist/{provision-CPx2ZxsH.mjs → provision-Blnstcm2.mjs} +78 -45
  99. package/dist/r2-conditions-D1Wk8i7b.mjs +30 -0
  100. package/dist/{requests-B8sZxaFM.mjs → requests-BcKOVpRg.mjs} +5 -3
  101. package/dist/{resolve-project-BBMtLLV9.mjs → resolve-project--Vxawf7z.mjs} +2 -2
  102. package/dist/rollback-Bx85-0xh.mjs +166 -0
  103. package/dist/{rolldown-runtime-DJK8HYOj.mjs → rolldown-runtime-rQ84J-ij.mjs} +1 -1
  104. package/dist/{route-types-z1jtHEi_.mjs → route-types-Da-DpyUp.mjs} +77 -25
  105. package/dist/routes-stub.d.mts +22 -23
  106. package/dist/runner-mysql-7BPUNGmL.mjs +61 -0
  107. package/dist/{runner-pg-CHM76xuC.mjs → runner-pg-BkEza-dX.mjs} +18 -6
  108. package/dist/runtime/ai.d.mts +21 -14
  109. package/dist/runtime/ai.mjs +5 -4
  110. package/dist/runtime/auth-client-react.d.mts +3 -5
  111. package/dist/runtime/auth-client-solid.d.mts +3 -5
  112. package/dist/runtime/auth-client-svelte.d.mts +3 -5
  113. package/dist/runtime/auth-client-vue.d.mts +3 -5
  114. package/dist/runtime/auth-client.d.mts +3 -5
  115. package/dist/runtime/auth.d.mts +1 -1
  116. package/dist/runtime/better-auth-mysql.d.mts +10 -0
  117. package/dist/runtime/better-auth-mysql.mjs +49 -0
  118. package/dist/runtime/better-auth-pg.d.mts +8 -9
  119. package/dist/runtime/better-auth-pg.mjs +2 -2
  120. package/dist/runtime/better-auth.d.mts +8 -9
  121. package/dist/runtime/better-auth.mjs +2 -2
  122. package/dist/runtime/client-react.d.mts +1 -1
  123. package/dist/runtime/client-solid.d.mts +1 -1
  124. package/dist/runtime/client-svelte.d.mts +1 -1
  125. package/dist/runtime/client-vue.d.mts +1 -1
  126. package/dist/runtime/client.d.mts +1 -1
  127. package/dist/runtime/db-mysql.d.mts +2 -0
  128. package/dist/runtime/db-mysql.mjs +1 -0
  129. package/dist/runtime/db.d.mts +10 -11
  130. package/dist/runtime/durable.d.mts +47 -0
  131. package/dist/runtime/durable.mjs +146 -0
  132. package/dist/runtime/email/testing.d.mts +112 -0
  133. package/dist/runtime/email/testing.mjs +283 -0
  134. package/dist/runtime/email.d.mts +30 -0
  135. package/dist/runtime/email.mjs +573 -0
  136. package/dist/runtime/env-helpers.d.mts +2 -2
  137. package/dist/runtime/env-helpers.mjs +5 -42
  138. package/dist/runtime/env-public-client.d.mts +10 -11
  139. package/dist/runtime/env-public-client.mjs +1 -1
  140. package/dist/runtime/env-public.d.mts +2 -2
  141. package/dist/runtime/env-public.mjs +104 -49
  142. package/dist/runtime/env.d.mts +19 -18
  143. package/dist/runtime/env.mjs +15 -2
  144. package/dist/runtime/fetch-stream.d.mts +20 -21
  145. package/dist/runtime/fetch.d.mts +15 -16
  146. package/dist/runtime/handler.d.mts +1 -1
  147. package/dist/runtime/isr.d.mts +21 -22
  148. package/dist/runtime/isr.mjs +26 -8
  149. package/dist/runtime/kv.d.mts +9 -10
  150. package/dist/runtime/live-client.d.mts +5 -7
  151. package/dist/runtime/live-client.mjs +9 -7
  152. package/dist/runtime/live-server.d.mts +4 -5
  153. package/dist/runtime/live.d.mts +22 -24
  154. package/dist/runtime/live.mjs +1 -1
  155. package/dist/runtime/log.d.mts +16 -17
  156. package/dist/runtime/migration-handler-mysql.d.mts +4 -0
  157. package/dist/runtime/migration-handler-mysql.mjs +81 -0
  158. package/dist/runtime/migration-handler-pg.d.mts +2 -4
  159. package/dist/runtime/migration-handler.d.mts +5 -6
  160. package/dist/runtime/migration-handler.mjs +4 -3
  161. package/dist/runtime/queues.d.mts +3 -4
  162. package/dist/runtime/queues.mjs +2 -1
  163. package/dist/runtime/remote/binding-handler.d.mts +10 -12
  164. package/dist/runtime/remote/binding-handler.mjs +24 -3
  165. package/dist/runtime/remote/index.d.mts +5 -6
  166. package/dist/runtime/remote/index.mjs +21 -18
  167. package/dist/runtime/response.d.mts +10 -11
  168. package/dist/runtime/sandbox.d.mts +56 -55
  169. package/dist/runtime/sandbox.mjs +57 -49
  170. package/dist/runtime/schema-mysql.d.mts +1 -0
  171. package/dist/runtime/schema-mysql.mjs +2 -0
  172. package/dist/runtime/seed.d.mts +14 -9
  173. package/dist/runtime/sse-client.d.mts +6 -7
  174. package/dist/runtime/sse.d.mts +11 -12
  175. package/dist/runtime/storage.d.mts +3 -4
  176. package/dist/runtime/validator.d.mts +1 -1
  177. package/dist/runtime/ws-server.d.mts +12 -12
  178. package/dist/runtime/ws-server.mjs +32 -4
  179. package/dist/runtime/ws.d.mts +19 -21
  180. package/dist/{scan-ChWt4pX1.mjs → scan-BMH4rzlv.mjs} +42 -19
  181. package/dist/{scan-NU4xKGci.mjs → scan-CpK-57ug.mjs} +5 -4
  182. package/dist/{secret-Dt32J6RI.mjs → secret-ByhJ9AMl.mjs} +62 -5
  183. package/dist/{skills-CLjN0uUO.mjs → skills-Q46GZMO-.mjs} +6 -4
  184. package/dist/sqlite-validation-BzKMWnO4.mjs +25 -0
  185. package/dist/{standard-schema-DJ0HW7QP.d.mts → standard-schema-Fo_vCAZh.d.mts} +6 -6
  186. package/dist/{subcommand-prompt-BzV8iQZo.mjs → subcommand-prompt-WfySCQ7S.mjs} +67 -48
  187. package/dist/sveltekit.d.mts +12 -11
  188. package/dist/sveltekit.mjs +1 -1
  189. package/dist/types-BAp5AEBU.d.mts +79 -0
  190. package/dist/types-CKWnYgfy.d.mts +1 -0
  191. package/dist/{validate-Cw_RLeTj.mjs → validate-tBBN_dXH.mjs} +4 -3
  192. package/dist/wrangler--imS8n0d.mjs +1796 -0
  193. package/dist/{yarn-pnp-DJn3SAHF.mjs → yarn-pnp-DxSInkzL.mjs} +1 -1
  194. package/package.json +79 -65
  195. package/schema.json +22 -3
  196. package/skills/void/SKILL.md +59 -2
  197. package/skills/void/docs/guide/ai.md +32 -14
  198. package/skills/void/docs/guide/app-types.md +6 -6
  199. package/skills/void/docs/guide/auth.md +14 -16
  200. package/skills/void/docs/guide/database/d1.md +6 -0
  201. package/skills/void/docs/guide/database/mysql.md +60 -0
  202. package/skills/void/docs/guide/database/postgresql.md +14 -9
  203. package/skills/void/docs/guide/database.md +39 -26
  204. package/skills/void/docs/guide/deployment.md +99 -25
  205. package/skills/void/docs/guide/durable-state.md +140 -0
  206. package/skills/void/docs/guide/edge/headers.md +5 -5
  207. package/skills/void/docs/guide/edge/prerendering.md +2 -0
  208. package/skills/void/docs/guide/edge/revalidation.md +21 -6
  209. package/skills/void/docs/guide/edge/rewrites.md +18 -14
  210. package/skills/void/docs/guide/edge/static-assets.md +12 -10
  211. package/skills/void/docs/guide/email.md +640 -0
  212. package/skills/void/docs/guide/env-migration.md +109 -0
  213. package/skills/void/docs/guide/env-vars.md +70 -248
  214. package/skills/void/docs/guide/index.md +15 -17
  215. package/skills/void/docs/guide/jobs.md +8 -5
  216. package/skills/void/docs/guide/live.md +7 -15
  217. package/skills/void/docs/guide/pages-routing/actions-and-forms.md +8 -4
  218. package/skills/void/docs/guide/pages-routing/islands.md +3 -3
  219. package/skills/void/docs/guide/pages-routing/loaders.md +6 -4
  220. package/skills/void/docs/guide/pages-routing/overview.md +7 -7
  221. package/skills/void/docs/guide/platform-administration.md +212 -0
  222. package/skills/void/docs/guide/platform-development.md +264 -0
  223. package/skills/void/docs/guide/queues.md +10 -10
  224. package/skills/void/docs/guide/quickstart.md +46 -67
  225. package/skills/void/docs/guide/remote-dev.md +8 -6
  226. package/skills/void/docs/guide/sandboxes.md +33 -16
  227. package/skills/void/docs/guide/self-hosted-platform.md +553 -0
  228. package/skills/void/docs/guide/server-routing.md +5 -5
  229. package/skills/void/docs/guide/sse.md +4 -4
  230. package/skills/void/docs/guide/ssg.md +5 -3
  231. package/skills/void/docs/guide/storage.md +2 -2
  232. package/skills/void/docs/guide/websockets.md +15 -7
  233. package/skills/void/docs/index.md +3 -3
  234. package/skills/void/docs/integrations/agents.md +6 -64
  235. package/skills/void/docs/integrations/cloudflare.md +165 -146
  236. package/skills/void/docs/integrations/frameworks/analog.md +4 -4
  237. package/skills/void/docs/integrations/frameworks/astro.md +5 -5
  238. package/skills/void/docs/integrations/frameworks/nuxt.md +5 -5
  239. package/skills/void/docs/integrations/frameworks/overview.md +3 -3
  240. package/skills/void/docs/integrations/frameworks/react-router.md +3 -3
  241. package/skills/void/docs/integrations/frameworks/sveltekit.md +3 -3
  242. package/skills/void/docs/integrations/frameworks/tanstack-start.md +2 -2
  243. package/skills/void/docs/integrations/nodejs-bun-deno.md +11 -4
  244. package/skills/void/docs/reference/api.md +42 -6
  245. package/skills/void/docs/reference/cli.md +665 -160
  246. package/skills/void/docs/reference/config.md +67 -27
  247. package/skills/void/docs/reference/resource-inference.md +13 -9
  248. package/skills/void/docs/reference/structure.md +9 -11
  249. package/AGENT_PROMPT.md +0 -19
  250. package/dist/cf-access-Bqw81xAf.mjs +0 -22
  251. package/dist/env-CZy5MorI.mjs +0 -299
  252. package/dist/env-helpers-z4stu8uc.d.mts +0 -52
  253. package/dist/env-mask-Dd47NbR6.mjs +0 -90
  254. package/dist/env-public-BfiLcMBk.d.mts +0 -140
  255. package/dist/link-CdGHSIy-.mjs +0 -45
  256. package/dist/mcp-DoM3_nhd.mjs +0 -377
  257. package/dist/project-paths-GpziKeQQ.d.mts +0 -25
  258. package/dist/providers-BNKRacMr.d.mts +0 -7
  259. package/dist/proxy-D-3_D-Gl.mjs +0 -5
  260. package/dist/rollback-CkvTFXx5.mjs +0 -90
  261. package/dist/runtime/isr-cache.d.mts +0 -207
  262. package/dist/runtime/isr-cache.mjs +0 -523
  263. package/dist/types-lLjNE9Qp.d.mts +0 -51
  264. package/getting-started-prompt.txt +0 -28
  265. package/skills/void/command/void.md +0 -7
  266. package/skills/void/docs/integrations/auth-providers.md +0 -0
  267. package/skills/void/docs/integrations/payment-processors.md +0 -0
  268. package/skills/void/docs/node_modules/@iconify/vue/README.md +0 -408
  269. package/skills/void/docs/node_modules/@iconify/vue/offline/readme.md +0 -5
  270. package/skills/void/docs/node_modules/@voidzero-dev/vitepress-theme/README.md +0 -103
  271. package/skills/void/docs/node_modules/oxc-minify/README.md +0 -78
  272. package/skills/void/docs/node_modules/reka-ui/README.md +0 -80
  273. package/skills/void/docs/node_modules/vitepress/README.md +0 -28
  274. package/skills/void/docs/node_modules/vitepress/template/api-examples.md +0 -49
  275. package/skills/void/docs/node_modules/vitepress/template/index.md +0 -28
  276. package/skills/void/docs/node_modules/vitepress/template/markdown-examples.md +0 -85
  277. package/skills/void/docs/node_modules/vitepress-plugin-group-icons/README.md +0 -101
  278. package/skills/void/docs/node_modules/void/AGENT_PROMPT.md +0 -19
  279. package/skills/void/docs/node_modules/void/CLAUDE.md +0 -221
  280. package/skills/void/docs/node_modules/void/README.md +0 -90
  281. package/skills/void/docs/node_modules/void/node_modules/@clack/prompts/CHANGELOG.md +0 -685
  282. package/skills/void/docs/node_modules/void/node_modules/@clack/prompts/README.md +0 -396
  283. package/skills/void/docs/node_modules/void/node_modules/@cloudflare/sandbox/README.md +0 -219
  284. package/skills/void/docs/node_modules/void/node_modules/@cloudflare/vite-plugin/README.md +0 -37
  285. package/skills/void/docs/node_modules/void/node_modules/@cloudflare/workers-types/README.md +0 -135
  286. package/skills/void/docs/node_modules/void/node_modules/@electric-sql/pglite/README.md +0 -189
  287. package/skills/void/docs/node_modules/void/node_modules/@hono/oauth-providers/CHANGELOG.md +0 -143
  288. package/skills/void/docs/node_modules/void/node_modules/@hono/oauth-providers/README.md +0 -1272
  289. package/skills/void/docs/node_modules/void/node_modules/@napi-rs/keyring/README.md +0 -19
  290. package/skills/void/docs/node_modules/void/node_modules/@types/better-sqlite3/README.md +0 -15
  291. package/skills/void/docs/node_modules/void/node_modules/@types/node/README.md +0 -15
  292. package/skills/void/docs/node_modules/void/node_modules/@types/pg/README.md +0 -15
  293. package/skills/void/docs/node_modules/void/node_modules/@types/proper-lockfile/README.md +0 -51
  294. package/skills/void/docs/node_modules/void/node_modules/@typescript/native-preview/README.md +0 -22
  295. package/skills/void/docs/node_modules/void/node_modules/@typescript/native-preview/vendor/vscode-jsonrpc/README.md +0 -69
  296. package/skills/void/docs/node_modules/void/node_modules/@void/md/README.md +0 -153
  297. package/skills/void/docs/node_modules/void/node_modules/@void/md/node_modules/@shikijs/engine-javascript/README.md +0 -9
  298. package/skills/void/docs/node_modules/void/node_modules/@void/md/node_modules/@shikijs/transformers/README.md +0 -9
  299. package/skills/void/docs/node_modules/void/node_modules/@void/md/node_modules/@types/node/README.md +0 -15
  300. package/skills/void/docs/node_modules/void/node_modules/@void/md/node_modules/gray-matter/CHANGELOG.md +0 -24
  301. package/skills/void/docs/node_modules/void/node_modules/@void/md/node_modules/gray-matter/README.md +0 -565
  302. package/skills/void/docs/node_modules/void/node_modules/@void/md/node_modules/markdown-exit/README.md +0 -127
  303. package/skills/void/docs/node_modules/void/node_modules/@void/md/node_modules/markdown-it-anchor/README.md +0 -600
  304. package/skills/void/docs/node_modules/void/node_modules/@void/md/node_modules/markdown-it-attrs/README.md +0 -386
  305. package/skills/void/docs/node_modules/void/node_modules/@void/md/node_modules/markdown-it-container/README.md +0 -95
  306. package/skills/void/docs/node_modules/void/node_modules/@void/md/node_modules/markdown-it-emoji/README.md +0 -101
  307. package/skills/void/docs/node_modules/void/node_modules/@void/md/node_modules/markdown-it-footnote/README.md +0 -135
  308. package/skills/void/docs/node_modules/void/node_modules/@void/md/node_modules/pathslash/README.md +0 -64
  309. package/skills/void/docs/node_modules/void/node_modules/@void/md/node_modules/shiki/README.md +0 -15
  310. package/skills/void/docs/node_modules/void/node_modules/@void/md/node_modules/tinyglobby/README.md +0 -25
  311. package/skills/void/docs/node_modules/void/node_modules/@void/md/node_modules/vite-plus/AGENTS.md +0 -16
  312. package/skills/void/docs/node_modules/void/node_modules/@void/md/node_modules/vite-plus/README.md +0 -220
  313. package/skills/void/docs/node_modules/void/node_modules/@void/md/node_modules/vite-plus/docs/config/build.md +0 -21
  314. package/skills/void/docs/node_modules/void/node_modules/@void/md/node_modules/vite-plus/docs/config/check.md +0 -35
  315. package/skills/void/docs/node_modules/void/node_modules/@void/md/node_modules/vite-plus/docs/config/create.md +0 -70
  316. package/skills/void/docs/node_modules/void/node_modules/@void/md/node_modules/vite-plus/docs/config/fmt.md +0 -20
  317. package/skills/void/docs/node_modules/void/node_modules/@void/md/node_modules/vite-plus/docs/config/index.md +0 -35
  318. package/skills/void/docs/node_modules/void/node_modules/@void/md/node_modules/vite-plus/docs/config/lint.md +0 -26
  319. package/skills/void/docs/node_modules/void/node_modules/@void/md/node_modules/vite-plus/docs/config/pack.md +0 -17
  320. package/skills/void/docs/node_modules/void/node_modules/@void/md/node_modules/vite-plus/docs/config/run.md +0 -364
  321. package/skills/void/docs/node_modules/void/node_modules/@void/md/node_modules/vite-plus/docs/config/staged.md +0 -15
  322. package/skills/void/docs/node_modules/void/node_modules/@void/md/node_modules/vite-plus/docs/config/test.md +0 -18
  323. package/skills/void/docs/node_modules/void/node_modules/@void/md/node_modules/vite-plus/docs/guide/automatic-data-tracking.md +0 -145
  324. package/skills/void/docs/node_modules/void/node_modules/@void/md/node_modules/vite-plus/docs/guide/build.md +0 -40
  325. package/skills/void/docs/node_modules/void/node_modules/@void/md/node_modules/vite-plus/docs/guide/cache.md +0 -107
  326. package/skills/void/docs/node_modules/void/node_modules/@void/md/node_modules/vite-plus/docs/guide/check.md +0 -60
  327. package/skills/void/docs/node_modules/void/node_modules/@void/md/node_modules/vite-plus/docs/guide/ci.md +0 -62
  328. package/skills/void/docs/node_modules/void/node_modules/@void/md/node_modules/vite-plus/docs/guide/commit-hooks.md +0 -60
  329. package/skills/void/docs/node_modules/void/node_modules/@void/md/node_modules/vite-plus/docs/guide/create.md +0 -341
  330. package/skills/void/docs/node_modules/void/node_modules/@void/md/node_modules/vite-plus/docs/guide/dev.md +0 -24
  331. package/skills/void/docs/node_modules/void/node_modules/@void/md/node_modules/vite-plus/docs/guide/docker.md +0 -175
  332. package/skills/void/docs/node_modules/void/node_modules/@void/md/node_modules/vite-plus/docs/guide/env.md +0 -167
  333. package/skills/void/docs/node_modules/void/node_modules/@void/md/node_modules/vite-plus/docs/guide/fmt.md +0 -41
  334. package/skills/void/docs/node_modules/void/node_modules/@void/md/node_modules/vite-plus/docs/guide/github-actions-cache.md +0 -165
  335. package/skills/void/docs/node_modules/void/node_modules/@void/md/node_modules/vite-plus/docs/guide/ide-integration.md +0 -101
  336. package/skills/void/docs/node_modules/void/node_modules/@void/md/node_modules/vite-plus/docs/guide/implode.md +0 -23
  337. package/skills/void/docs/node_modules/void/node_modules/@void/md/node_modules/vite-plus/docs/guide/index.md +0 -134
  338. package/skills/void/docs/node_modules/void/node_modules/@void/md/node_modules/vite-plus/docs/guide/install.md +0 -199
  339. package/skills/void/docs/node_modules/void/node_modules/@void/md/node_modules/vite-plus/docs/guide/lint.md +0 -50
  340. package/skills/void/docs/node_modules/void/node_modules/@void/md/node_modules/vite-plus/docs/guide/migrate-rules.md +0 -347
  341. package/skills/void/docs/node_modules/void/node_modules/@void/md/node_modules/vite-plus/docs/guide/migrate.md +0 -197
  342. package/skills/void/docs/node_modules/void/node_modules/@void/md/node_modules/vite-plus/docs/guide/monorepo.md +0 -176
  343. package/skills/void/docs/node_modules/void/node_modules/@void/md/node_modules/vite-plus/docs/guide/pack.md +0 -69
  344. package/skills/void/docs/node_modules/void/node_modules/@void/md/node_modules/vite-plus/docs/guide/run.md +0 -356
  345. package/skills/void/docs/node_modules/void/node_modules/@void/md/node_modules/vite-plus/docs/guide/test.md +0 -35
  346. package/skills/void/docs/node_modules/void/node_modules/@void/md/node_modules/vite-plus/docs/guide/troubleshooting.md +0 -108
  347. package/skills/void/docs/node_modules/void/node_modules/@void/md/node_modules/vite-plus/docs/guide/upgrade.md +0 -101
  348. package/skills/void/docs/node_modules/void/node_modules/@void/md/node_modules/vite-plus/docs/guide/vpx.md +0 -66
  349. package/skills/void/docs/node_modules/void/node_modules/@void/md/node_modules/vite-plus/docs/guide/why.md +0 -39
  350. package/skills/void/docs/node_modules/void/node_modules/@void/md/node_modules/vite-plus/docs/index.md +0 -12
  351. package/skills/void/docs/node_modules/void/node_modules/@void/md/node_modules/vite-plus/docs/team.md +0 -35
  352. package/skills/void/docs/node_modules/void/node_modules/@void/md/node_modules/vite-plus/templates/generator/README.md +0 -35
  353. package/skills/void/docs/node_modules/void/node_modules/@void/md/node_modules/vite-plus/templates/monorepo/README.md +0 -29
  354. package/skills/void/docs/node_modules/void/node_modules/@void/md/node_modules/vue/README.md +0 -58
  355. package/skills/void/docs/node_modules/void/node_modules/arktype/README.md +0 -165
  356. package/skills/void/docs/node_modules/void/node_modules/better-auth/LICENSE.md +0 -20
  357. package/skills/void/docs/node_modules/void/node_modules/better-auth/README.md +0 -32
  358. package/skills/void/docs/node_modules/void/node_modules/better-sqlite3/README.md +0 -99
  359. package/skills/void/docs/node_modules/void/node_modules/blake3-jit/README.md +0 -108
  360. package/skills/void/docs/node_modules/void/node_modules/drizzle-arktype/README.md +0 -51
  361. package/skills/void/docs/node_modules/void/node_modules/drizzle-kit/README.md +0 -79
  362. package/skills/void/docs/node_modules/void/node_modules/drizzle-orm/README.md +0 -44
  363. package/skills/void/docs/node_modules/void/node_modules/drizzle-valibot/README.md +0 -51
  364. package/skills/void/docs/node_modules/void/node_modules/drizzle-zod/README.md +0 -65
  365. package/skills/void/docs/node_modules/void/node_modules/es-module-lexer/README.md +0 -403
  366. package/skills/void/docs/node_modules/void/node_modules/estree-walker/README.md +0 -48
  367. package/skills/void/docs/node_modules/void/node_modules/hono/README.md +0 -85
  368. package/skills/void/docs/node_modules/void/node_modules/ignore/README.md +0 -452
  369. package/skills/void/docs/node_modules/void/node_modules/jsonc-parser/CHANGELOG.md +0 -76
  370. package/skills/void/docs/node_modules/void/node_modules/jsonc-parser/LICENSE.md +0 -21
  371. package/skills/void/docs/node_modules/void/node_modules/jsonc-parser/README.md +0 -364
  372. package/skills/void/docs/node_modules/void/node_modules/jsonc-parser/SECURITY.md +0 -41
  373. package/skills/void/docs/node_modules/void/node_modules/magic-string/README.md +0 -325
  374. package/skills/void/docs/node_modules/void/node_modules/ofetch/README.md +0 -398
  375. package/skills/void/docs/node_modules/void/node_modules/pathslash/README.md +0 -64
  376. package/skills/void/docs/node_modules/void/node_modules/pg/README.md +0 -96
  377. package/skills/void/docs/node_modules/void/node_modules/pglite-server/README.md +0 -135
  378. package/skills/void/docs/node_modules/void/node_modules/picocolors/README.md +0 -21
  379. package/skills/void/docs/node_modules/void/node_modules/proper-lockfile/CHANGELOG.md +0 -108
  380. package/skills/void/docs/node_modules/void/node_modules/proper-lockfile/README.md +0 -183
  381. package/skills/void/docs/node_modules/void/node_modules/tinyglobby/README.md +0 -25
  382. package/skills/void/docs/node_modules/void/node_modules/valibot/LICENSE.md +0 -9
  383. package/skills/void/docs/node_modules/void/node_modules/valibot/README.md +0 -94
  384. package/skills/void/docs/node_modules/void/node_modules/vite-plus/AGENTS.md +0 -16
  385. package/skills/void/docs/node_modules/void/node_modules/vite-plus/README.md +0 -220
  386. package/skills/void/docs/node_modules/void/node_modules/vite-plus/docs/config/build.md +0 -21
  387. package/skills/void/docs/node_modules/void/node_modules/vite-plus/docs/config/check.md +0 -35
  388. package/skills/void/docs/node_modules/void/node_modules/vite-plus/docs/config/create.md +0 -70
  389. package/skills/void/docs/node_modules/void/node_modules/vite-plus/docs/config/fmt.md +0 -20
  390. package/skills/void/docs/node_modules/void/node_modules/vite-plus/docs/config/index.md +0 -35
  391. package/skills/void/docs/node_modules/void/node_modules/vite-plus/docs/config/lint.md +0 -26
  392. package/skills/void/docs/node_modules/void/node_modules/vite-plus/docs/config/pack.md +0 -17
  393. package/skills/void/docs/node_modules/void/node_modules/vite-plus/docs/config/run.md +0 -364
  394. package/skills/void/docs/node_modules/void/node_modules/vite-plus/docs/config/staged.md +0 -15
  395. package/skills/void/docs/node_modules/void/node_modules/vite-plus/docs/config/test.md +0 -18
  396. package/skills/void/docs/node_modules/void/node_modules/vite-plus/docs/guide/automatic-data-tracking.md +0 -145
  397. package/skills/void/docs/node_modules/void/node_modules/vite-plus/docs/guide/build.md +0 -40
  398. package/skills/void/docs/node_modules/void/node_modules/vite-plus/docs/guide/cache.md +0 -107
  399. package/skills/void/docs/node_modules/void/node_modules/vite-plus/docs/guide/check.md +0 -60
  400. package/skills/void/docs/node_modules/void/node_modules/vite-plus/docs/guide/ci.md +0 -62
  401. package/skills/void/docs/node_modules/void/node_modules/vite-plus/docs/guide/commit-hooks.md +0 -60
  402. package/skills/void/docs/node_modules/void/node_modules/vite-plus/docs/guide/create.md +0 -341
  403. package/skills/void/docs/node_modules/void/node_modules/vite-plus/docs/guide/dev.md +0 -24
  404. package/skills/void/docs/node_modules/void/node_modules/vite-plus/docs/guide/docker.md +0 -175
  405. package/skills/void/docs/node_modules/void/node_modules/vite-plus/docs/guide/env.md +0 -167
  406. package/skills/void/docs/node_modules/void/node_modules/vite-plus/docs/guide/fmt.md +0 -41
  407. package/skills/void/docs/node_modules/void/node_modules/vite-plus/docs/guide/github-actions-cache.md +0 -165
  408. package/skills/void/docs/node_modules/void/node_modules/vite-plus/docs/guide/ide-integration.md +0 -101
  409. package/skills/void/docs/node_modules/void/node_modules/vite-plus/docs/guide/implode.md +0 -23
  410. package/skills/void/docs/node_modules/void/node_modules/vite-plus/docs/guide/index.md +0 -134
  411. package/skills/void/docs/node_modules/void/node_modules/vite-plus/docs/guide/install.md +0 -199
  412. package/skills/void/docs/node_modules/void/node_modules/vite-plus/docs/guide/lint.md +0 -50
  413. package/skills/void/docs/node_modules/void/node_modules/vite-plus/docs/guide/migrate-rules.md +0 -347
  414. package/skills/void/docs/node_modules/void/node_modules/vite-plus/docs/guide/migrate.md +0 -197
  415. package/skills/void/docs/node_modules/void/node_modules/vite-plus/docs/guide/monorepo.md +0 -176
  416. package/skills/void/docs/node_modules/void/node_modules/vite-plus/docs/guide/pack.md +0 -69
  417. package/skills/void/docs/node_modules/void/node_modules/vite-plus/docs/guide/run.md +0 -356
  418. package/skills/void/docs/node_modules/void/node_modules/vite-plus/docs/guide/test.md +0 -35
  419. package/skills/void/docs/node_modules/void/node_modules/vite-plus/docs/guide/troubleshooting.md +0 -108
  420. package/skills/void/docs/node_modules/void/node_modules/vite-plus/docs/guide/upgrade.md +0 -101
  421. package/skills/void/docs/node_modules/void/node_modules/vite-plus/docs/guide/vpx.md +0 -66
  422. package/skills/void/docs/node_modules/void/node_modules/vite-plus/docs/guide/why.md +0 -39
  423. package/skills/void/docs/node_modules/void/node_modules/vite-plus/docs/index.md +0 -12
  424. package/skills/void/docs/node_modules/void/node_modules/vite-plus/docs/team.md +0 -35
  425. package/skills/void/docs/node_modules/void/node_modules/vite-plus/templates/generator/README.md +0 -35
  426. package/skills/void/docs/node_modules/void/node_modules/vite-plus/templates/monorepo/README.md +0 -29
  427. package/skills/void/docs/node_modules/void/node_modules/wrangler/README.md +0 -63
  428. package/skills/void/docs/node_modules/void/node_modules/zod/README.md +0 -191
  429. package/skills/void/docs/node_modules/void/skills/migrate-vite-cloudflare-to-void/SKILL.md +0 -175
  430. package/skills/void/docs/node_modules/void/skills/void/SKILL.md +0 -76
  431. package/skills/void/docs/node_modules/void/skills/void/command/void.md +0 -7
  432. package/skills/void/docs/node_modules/void/test/e2e/README.md +0 -85
@@ -1,7 +1,11 @@
1
- import { n as __exportAll, r as __toESM, t as __commonJSMin } from "./rolldown-runtime-DJK8HYOj.mjs";
2
- import { a as join } from "./dist-DaKKDf8D.mjs";
3
- import { existsSync, readFileSync } from "node:fs";
1
+ import { n as __exportAll, r as __toESM, t as __commonJSMin } from "./rolldown-runtime-rQ84J-ij.mjs";
2
+ import { l as resolve, o as join } from "./dist-BrsS7cai.mjs";
3
+ import { closeSync, existsSync, mkdirSync, openSync, readFileSync, readdirSync, renameSync, rmSync, statSync, writeFileSync } from "node:fs";
4
4
  import { fileURLToPath } from "node:url";
5
+ import { createCipheriv, createDecipheriv, createHash, randomBytes } from "node:crypto";
6
+ import { homedir, hostname } from "node:os";
7
+ import { Entry } from "@napi-rs/keyring";
8
+ import { parsePlatformInstallationManifest } from "@void/platform";
5
9
  import { styleText } from "node:util";
6
10
  import process$1, { stdin, stdout } from "node:process";
7
11
  import * as l from "node:readline";
@@ -9,7 +13,9 @@ import l__default from "node:readline";
9
13
  import { ReadStream } from "node:tty";
10
14
  //#region ../../node_modules/.pnpm/picocolors@1.1.1/node_modules/picocolors/picocolors.js
11
15
  var require_picocolors = /* @__PURE__ */ __commonJSMin(((exports, module) => {
12
- let p = process || {}, argv = p.argv || [], env = p.env || {};
16
+ let p = process || {};
17
+ let argv = p.argv || [];
18
+ let env = p.env || {};
13
19
  let isColorSupported = !(!!env.NO_COLOR || argv.includes("--no-color")) && (!!env.FORCE_COLOR || argv.includes("--color") || p.platform === "win32" || (p.stdout || {}).isTTY && env.TERM !== "dumb" || !!env.CI);
14
20
  let formatter = (open, close, replace = open) => (input) => {
15
21
  let string = "" + input, index = string.indexOf(close, open.length);
@@ -75,6 +81,430 @@ var require_picocolors = /* @__PURE__ */ __commonJSMin(((exports, module) => {
75
81
  module.exports.createColors = createColors;
76
82
  }));
77
83
  //#endregion
84
+ //#region src/cli/keyring.ts
85
+ function readKeyringPassword(service, account) {
86
+ try {
87
+ return new Entry(service, account).getPassword();
88
+ } catch {
89
+ return null;
90
+ }
91
+ }
92
+ function writeKeyringPassword(service, account, password) {
93
+ try {
94
+ new Entry(service, account).setPassword(password);
95
+ return true;
96
+ } catch {
97
+ return false;
98
+ }
99
+ }
100
+ function deleteKeyringPassword(service, account) {
101
+ try {
102
+ new Entry(service, account).deletePassword();
103
+ return true;
104
+ } catch {
105
+ return false;
106
+ }
107
+ }
108
+ const DEFAULT_REGISTRY = {
109
+ activeConnectionId: null,
110
+ connections: [],
111
+ schemaVersion: 1
112
+ };
113
+ const PLATFORM_RECOVERY_KEYRING_SERVICE = "dev.void.cli.platform";
114
+ const PLATFORM_RECOVERY_ENVELOPE_VERSION = 1;
115
+ function platformRegistryDirectory() {
116
+ return process.env.VOID_PLATFORM_REGISTRY_DIR ?? join(homedir(), ".void", "platforms");
117
+ }
118
+ function normalizePlatformApiUrl(value) {
119
+ let url;
120
+ try {
121
+ url = new URL(value);
122
+ } catch {
123
+ throw new Error(`platform: Invalid platform URL ${JSON.stringify(value)}.`);
124
+ }
125
+ if (!(url.protocol === "http:" && (url.hostname === "localhost" || url.hostname === "127.0.0.1" || url.hostname === "::1")) && url.protocol !== "https:" || url.username || url.password) throw new Error("platform: Platform URLs must use HTTPS and must not contain credentials.");
126
+ if (url.search || url.hash) throw new Error("platform: Platform URLs must not contain query parameters or fragments.");
127
+ if (url.pathname !== "/" && url.pathname !== "") throw new Error("platform: Platform URLs must not contain a path.");
128
+ return url.origin;
129
+ }
130
+ function platformConnectionId(apiUrl) {
131
+ return createHash("sha256").update(normalizePlatformApiUrl(apiUrl)).digest("hex").slice(0, 20);
132
+ }
133
+ function platformCredentialAccount(apiUrl) {
134
+ return `platform:${createHash("sha256").update(normalizePlatformApiUrl(apiUrl)).digest("hex")}`;
135
+ }
136
+ function parseConnection(value) {
137
+ if (!value || typeof value !== "object" || Array.isArray(value)) throw new Error("platform: Invalid connection entry in the local registry.");
138
+ const entry = value;
139
+ const apiUrl = normalizePlatformApiUrl(String(entry.apiUrl ?? ""));
140
+ const id = String(entry.id ?? "");
141
+ if (id !== platformConnectionId(apiUrl)) throw new Error("platform: Connection id does not match its API URL.");
142
+ if (entry.kind !== "connected" && entry.kind !== "installed") throw new Error("platform: Invalid connection kind in the local registry.");
143
+ const lastUsedAt = String(entry.lastUsedAt ?? "");
144
+ if (!Number.isFinite(Date.parse(lastUsedAt))) throw new Error("platform: Invalid connection timestamp in the local registry.");
145
+ const optionalString = (input) => typeof input === "string" && input !== "" ? input : null;
146
+ const proxyUrl = optionalString(entry.proxyUrl) ?? (apiUrl === "https://api.void.cloud" ? "https://proxy.void.cloud" : apiUrl === "https://api.staging.void.cloud" ? "https://proxy.staging.void.cloud" : null);
147
+ return {
148
+ accountId: optionalString(entry.accountId),
149
+ apiUrl,
150
+ applicationDomain: optionalString(entry.applicationDomain),
151
+ displayName: typeof entry.displayName === "string" && entry.displayName.trim() ? entry.displayName.trim() : new URL(apiUrl).hostname,
152
+ id,
153
+ installationId: optionalString(entry.installationId),
154
+ kind: entry.kind,
155
+ lastUsedAt,
156
+ proxyUrl: proxyUrl === null ? null : normalizePlatformApiUrl(proxyUrl)
157
+ };
158
+ }
159
+ function readRegistry(directory) {
160
+ try {
161
+ const parsed = JSON.parse(readFileSync(join(directory, "registry.json"), "utf8"));
162
+ if (!parsed || typeof parsed !== "object" || Array.isArray(parsed)) throw new Error("registry must be an object");
163
+ const value = parsed;
164
+ if (value.schemaVersion !== 1 || !Array.isArray(value.connections)) throw new Error("unsupported schema");
165
+ const connections = value.connections.map(parseConnection);
166
+ return {
167
+ activeConnectionId: typeof value.activeConnectionId === "string" && connections.some((connection) => connection.id === value.activeConnectionId) ? value.activeConnectionId : null,
168
+ connections,
169
+ schemaVersion: 1
170
+ };
171
+ } catch (error) {
172
+ if (error.code === "ENOENT") return DEFAULT_REGISTRY;
173
+ throw new Error(`platform: Could not read ${join(directory, "registry.json")}: ${error instanceof Error ? error.message : String(error)}`);
174
+ }
175
+ }
176
+ function withRegistryLock(directory, operation) {
177
+ mkdirSync(directory, {
178
+ recursive: true,
179
+ mode: 448
180
+ });
181
+ const lockPath = join(directory, ".registry.lock");
182
+ let descriptor;
183
+ try {
184
+ descriptor = openSync(lockPath, "wx", 384);
185
+ } catch (error) {
186
+ if (error.code !== "EEXIST") throw error;
187
+ if (Date.now() - statSync(lockPath).mtimeMs < 6e5) throw new Error("platform: Another process is updating the platform registry.");
188
+ rmSync(lockPath, { force: true });
189
+ descriptor = openSync(lockPath, "wx", 384);
190
+ }
191
+ try {
192
+ return operation();
193
+ } finally {
194
+ closeSync(descriptor);
195
+ rmSync(lockPath, { force: true });
196
+ }
197
+ }
198
+ function writeJsonAtomically(path, value) {
199
+ const temporary = `${path}.${process.pid}.${randomBytes(6).toString("hex")}.tmp`;
200
+ try {
201
+ writeFileSync(temporary, `${JSON.stringify(value, null, 2)}\n`, {
202
+ mode: 384,
203
+ flag: "wx"
204
+ });
205
+ renameSync(temporary, path);
206
+ } finally {
207
+ rmSync(temporary, { force: true });
208
+ }
209
+ }
210
+ function acquirePlatformLifecycleLock(accountId, installationSlug, directory = platformRegistryDirectory()) {
211
+ if (!/^[A-Za-z0-9_-]+$/.test(accountId) || !/^[a-z0-9][a-z0-9-]{0,79}$/.test(installationSlug)) throw new Error("platform: Invalid lifecycle lock identity.");
212
+ const lockDirectory = join(directory, "locks");
213
+ mkdirSync(lockDirectory, {
214
+ recursive: true,
215
+ mode: 448
216
+ });
217
+ const lockPath = join(lockDirectory, `${accountId}-${installationSlug}.lock`);
218
+ const acquire = () => {
219
+ try {
220
+ const descriptor = openSync(lockPath, "wx", 384);
221
+ writeFileSync(descriptor, `${JSON.stringify({
222
+ host: hostname(),
223
+ pid: process.pid,
224
+ startedAt: (/* @__PURE__ */ new Date()).toISOString()
225
+ })}\n`);
226
+ return descriptor;
227
+ } catch (error) {
228
+ if (error.code !== "EEXIST") throw error;
229
+ let stale = false;
230
+ try {
231
+ const owner = JSON.parse(readFileSync(lockPath, "utf8"));
232
+ if (owner.host === hostname() && typeof owner.pid === "number") try {
233
+ process.kill(owner.pid, 0);
234
+ } catch (ownerError) {
235
+ stale = ownerError.code === "ESRCH";
236
+ }
237
+ else {
238
+ const startedAt = typeof owner.startedAt === "string" ? Date.parse(owner.startedAt) : NaN;
239
+ stale = Number.isFinite(startedAt) && Date.now() - startedAt > 72e5;
240
+ }
241
+ } catch {
242
+ stale = Date.now() - statSync(lockPath).mtimeMs > 72e5;
243
+ }
244
+ if (!stale) throw new Error(`platform: Another lifecycle operation is active for ${installationSlug} in account ${accountId}.`);
245
+ rmSync(lockPath, { force: true });
246
+ return acquire();
247
+ }
248
+ };
249
+ const descriptor = acquire();
250
+ let released = false;
251
+ return () => {
252
+ if (released) return;
253
+ released = true;
254
+ closeSync(descriptor);
255
+ rmSync(lockPath, { force: true });
256
+ };
257
+ }
258
+ function listPlatformConnections(directory = platformRegistryDirectory()) {
259
+ return readRegistry(directory).connections;
260
+ }
261
+ function assertPlatformInstallationSlugAvailable(installationSlug, directory = platformRegistryDirectory()) {
262
+ const collision = listInstallationManifests(directory).find((manifest) => manifest.status !== "uninstalled" && manifest.deployment.installationSlug === installationSlug);
263
+ if (collision) throw new Error(`platform: Installation ${collision.id} already uses this name. Resume it with \`void platform install --resume --name ${collision.id}\`.`);
264
+ }
265
+ function getActivePlatformConnection(directory = platformRegistryDirectory()) {
266
+ const registry = readRegistry(directory);
267
+ return registry.connections.find((connection) => connection.id === registry.activeConnectionId) ?? (registry.connections.length === 1 ? registry.connections[0] : null);
268
+ }
269
+ function savePlatformConnection(input, directory = platformRegistryDirectory()) {
270
+ const apiUrl = normalizePlatformApiUrl(input.apiUrl);
271
+ const id = platformConnectionId(apiUrl);
272
+ const lastUsedAt = input.lastUsedAt ?? (/* @__PURE__ */ new Date()).toISOString();
273
+ const connection = parseConnection({
274
+ ...input,
275
+ apiUrl,
276
+ id,
277
+ lastUsedAt
278
+ });
279
+ return withRegistryLock(directory, () => {
280
+ const connections = readRegistry(directory).connections.filter((entry) => entry.id !== id);
281
+ connections.push(connection);
282
+ connections.sort((left, right) => left.displayName.localeCompare(right.displayName));
283
+ writeJsonAtomically(join(directory, "registry.json"), {
284
+ activeConnectionId: id,
285
+ connections,
286
+ schemaVersion: 1
287
+ });
288
+ return connection;
289
+ });
290
+ }
291
+ function selectPlatformConnection(selector, directory = platformRegistryDirectory()) {
292
+ return withRegistryLock(directory, () => {
293
+ const current = readRegistry(directory);
294
+ const normalizedUrl = (() => {
295
+ try {
296
+ return normalizePlatformApiUrl(selector);
297
+ } catch {
298
+ return null;
299
+ }
300
+ })();
301
+ const matches = current.connections.filter((entry) => entry.id === selector || entry.installationId === selector || entry.displayName.toLowerCase() === selector.toLowerCase() || normalizedUrl !== null && entry.apiUrl === normalizedUrl);
302
+ if (matches.length !== 1) throw new Error(matches.length === 0 ? `platform: No installed or connected platform matches ${JSON.stringify(selector)}.` : `platform: More than one platform matches ${JSON.stringify(selector)}. Use its id or URL.`);
303
+ const selected = {
304
+ ...matches[0],
305
+ lastUsedAt: (/* @__PURE__ */ new Date()).toISOString()
306
+ };
307
+ const connections = current.connections.map((entry) => entry.id === selected.id ? selected : entry);
308
+ writeJsonAtomically(join(directory, "registry.json"), {
309
+ activeConnectionId: selected.id,
310
+ connections,
311
+ schemaVersion: 1
312
+ });
313
+ return selected;
314
+ });
315
+ }
316
+ function installationManifestPath(accountId, installationId, directory = platformRegistryDirectory()) {
317
+ if (!/^[A-Za-z0-9_-]+$/.test(accountId) || !/^[a-z0-9][a-z0-9-]{7,79}$/.test(installationId)) throw new Error("platform: Invalid account or installation id.");
318
+ return join(directory, accountId, `${installationId}.json`);
319
+ }
320
+ function writeInstallationManifest(manifest, directory = platformRegistryDirectory()) {
321
+ const path = installationManifestPath(manifest.account.id, manifest.id, directory);
322
+ const parent = join(directory, manifest.account.id);
323
+ mkdirSync(parent, {
324
+ recursive: true,
325
+ mode: 448
326
+ });
327
+ writeJsonAtomically(path, manifest);
328
+ }
329
+ function listInstallationManifests(directory = platformRegistryDirectory()) {
330
+ const manifests = [];
331
+ let accountDirectories;
332
+ try {
333
+ accountDirectories = readdirSync(directory, { withFileTypes: true }).filter((entry) => entry.isDirectory()).map((entry) => entry.name);
334
+ } catch (error) {
335
+ if (error.code === "ENOENT") return [];
336
+ throw error;
337
+ }
338
+ for (const accountId of accountDirectories) {
339
+ const accountPath = join(directory, accountId);
340
+ for (const entry of readdirSync(accountPath, { withFileTypes: true })) {
341
+ if (!entry.isFile() || !entry.name.endsWith(".json")) continue;
342
+ const path = join(accountPath, entry.name);
343
+ try {
344
+ manifests.push(parsePlatformInstallationManifest(JSON.parse(readFileSync(path, "utf8"))));
345
+ } catch (error) {
346
+ throw new Error(`platform: Invalid installation manifest ${path}: ${error instanceof Error ? error.message : String(error)}`);
347
+ }
348
+ }
349
+ }
350
+ return manifests.sort((left, right) => left.deployment.displayName.localeCompare(right.deployment.displayName));
351
+ }
352
+ function resolveInstallationManifest(selector, directory = platformRegistryDirectory()) {
353
+ const manifests = listInstallationManifests(directory).filter((manifest) => manifest.status !== "uninstalled" && (!selector || manifest.id === selector || manifest.deployment.installationSlug === selector || manifest.deployment.displayName.toLowerCase() === selector.toLowerCase()));
354
+ if (manifests.length !== 1) throw new Error(manifests.length === 0 ? `platform: No local installation matches ${JSON.stringify(selector)}.` : "platform: Multiple local installations match; specify an installation id.");
355
+ return manifests[0];
356
+ }
357
+ function writePendingInstallationSecrets(manifest, secrets, directory = platformRegistryDirectory()) {
358
+ const manifestPath = installationManifestPath(manifest.account.id, manifest.id, directory);
359
+ writeEncryptedRecoveryMaterial(manifest, "pending", manifestPath.replace(/\.json$/, ".secrets.enc"), secrets, directory);
360
+ rmSync(manifestPath.replace(/\.json$/, ".secrets"), { force: true });
361
+ }
362
+ function readPendingInstallationSecrets(manifest, directory = platformRegistryDirectory()) {
363
+ return readRecoveryMaterial(manifest, "pending", directory);
364
+ }
365
+ function promoteInstallationSecrets(manifest, directory = platformRegistryDirectory()) {
366
+ const manifestPath = installationManifestPath(manifest.account.id, manifest.id, directory);
367
+ const values = readPendingInstallationSecrets(manifest, directory);
368
+ if (!values) throw new Error("platform: Pending installation recovery material is missing.");
369
+ writeEncryptedRecoveryMaterial(manifest, "recovery", manifestPath.replace(/\.json$/, ".recovery.enc"), values, directory);
370
+ rmSync(manifestPath.replace(/\.json$/, ".secrets.enc"), { force: true });
371
+ rmSync(manifestPath.replace(/\.json$/, ".secrets"), { force: true });
372
+ rmSync(manifestPath.replace(/\.json$/, ".recovery"), { force: true });
373
+ }
374
+ function readInstallationRecoverySecrets(manifest, directory = platformRegistryDirectory()) {
375
+ const pending = readPendingInstallationSecrets(manifest, directory);
376
+ if (!pending) return readRecoveryMaterial(manifest, "recovery", directory);
377
+ const updateState = pendingWorkerSecretUpdateState(manifest, pending.workerSecretUpdatesJson);
378
+ if (updateState === "stale") return readRecoveryMaterial(manifest, "recovery", directory);
379
+ if (updateState === "committed") return Object.fromEntries(Object.entries(pending).filter(([name]) => name !== "workerSecretUpdatesJson"));
380
+ return pending;
381
+ }
382
+ function pendingWorkerSecretUpdateState(manifest, value) {
383
+ if (!value) return "active";
384
+ let parsed;
385
+ try {
386
+ parsed = JSON.parse(value);
387
+ } catch {
388
+ return "active";
389
+ }
390
+ if (!parsed || typeof parsed !== "object" || !("schema" in parsed) || parsed.schema !== 1 || !("id" in parsed) || typeof parsed.id !== "string" || !("baselineGeneration" in parsed) || !Number.isSafeInteger(parsed.baselineGeneration) || !("generation" in parsed) || parsed.generation !== null && !Number.isSafeInteger(parsed.generation)) return "active";
391
+ return platformWorkerSecretUpdateIntentState(manifest, {
392
+ baselineGeneration: Number(parsed.baselineGeneration),
393
+ generation: parsed.generation === null ? null : Number(parsed.generation),
394
+ id: parsed.id
395
+ });
396
+ }
397
+ function platformWorkerSecretUpdateIntentState(manifest, intent) {
398
+ const latestGeneration = latestPlatformWorkerCutoverGeneration(manifest);
399
+ const latestState = manifest.steps.flatMap((step) => {
400
+ const match = /^worker-secret-updates:(\d+):(pending|committed)$/.exec(step.key);
401
+ return match ? [{
402
+ generation: Number(match[1]),
403
+ id: step.resultHash,
404
+ state: match[2]
405
+ }] : [];
406
+ }).sort((left, right) => right.generation - left.generation || (left.state === right.state ? 0 : left.state === "committed" ? -1 : 1))[0];
407
+ if (!latestState) return intent.generation === null && intent.baselineGeneration === latestGeneration ? "active" : "stale";
408
+ if (latestState.generation !== latestGeneration || latestState.id !== intent.id) return "stale";
409
+ return latestState.state === "committed" ? "committed" : "active";
410
+ }
411
+ function latestPlatformWorkerCutoverGeneration(manifest) {
412
+ return Math.max(0, ...manifest.steps.flatMap((step) => {
413
+ const match = /^worker-(?:cutover|secret-updates|traffic-state):(\d+)/.exec(step.key);
414
+ return match ? [Number(match[1])] : [];
415
+ }));
416
+ }
417
+ function removeInstallationRecoverySecrets(manifest, directory = platformRegistryDirectory()) {
418
+ const manifestPath = installationManifestPath(manifest.account.id, manifest.id, directory);
419
+ rmSync(manifestPath.replace(/\.json$/, ".recovery.enc"), { force: true });
420
+ rmSync(manifestPath.replace(/\.json$/, ".secrets.enc"), { force: true });
421
+ rmSync(manifestPath.replace(/\.json$/, ".recovery"), { force: true });
422
+ rmSync(manifestPath.replace(/\.json$/, ".secrets"), { force: true });
423
+ }
424
+ function readRecoveryMaterial(manifest, kind, directory) {
425
+ const manifestPath = installationManifestPath(manifest.account.id, manifest.id, directory);
426
+ const encryptedPath = manifestPath.replace(/\.json$/, `.${kind === "pending" ? "secrets" : "recovery"}.enc`);
427
+ try {
428
+ const envelope = parseRecoveryEnvelope(JSON.parse(readFileSync(encryptedPath, "utf8")));
429
+ const key = platformRecoveryKey(directory, false);
430
+ if (!key) throw new Error("the encryption key is unavailable; restore it from the system keychain or set VOID_PLATFORM_RECOVERY_KEY");
431
+ const decipher = createDecipheriv("aes-256-gcm", key, Buffer.from(envelope.iv, "base64"));
432
+ decipher.setAAD(recoveryAad(manifest, kind));
433
+ decipher.setAuthTag(Buffer.from(envelope.tag, "base64"));
434
+ const plaintext = Buffer.concat([decipher.update(Buffer.from(envelope.ciphertext, "base64")), decipher.final()]);
435
+ return parseRecoveryValues(JSON.parse(plaintext.toString("utf8")), `${kind} recovery material`);
436
+ } catch (error) {
437
+ if (error.code !== "ENOENT") throw new Error(`platform: Could not read encrypted ${kind} material: ${error instanceof Error ? error.message : String(error)}`);
438
+ }
439
+ const legacyPath = manifestPath.replace(/\.json$/, kind === "pending" ? ".secrets" : ".recovery");
440
+ try {
441
+ const values = parseRecoveryValues(JSON.parse(readFileSync(legacyPath, "utf8")), `legacy ${kind} recovery material`);
442
+ writeEncryptedRecoveryMaterial(manifest, kind, encryptedPath, values, directory);
443
+ rmSync(legacyPath, { force: true });
444
+ return values;
445
+ } catch (error) {
446
+ if (error.code === "ENOENT") return null;
447
+ throw new Error(`platform: Could not migrate legacy ${kind} material: ${error instanceof Error ? error.message : String(error)}`);
448
+ }
449
+ }
450
+ function writeEncryptedRecoveryMaterial(manifest, kind, path, values, directory) {
451
+ const key = platformRecoveryKey(directory, true);
452
+ const iv = randomBytes(12);
453
+ const cipher = createCipheriv("aes-256-gcm", key, iv);
454
+ cipher.setAAD(recoveryAad(manifest, kind));
455
+ writeJsonAtomically(path, {
456
+ algorithm: "aes-256-gcm",
457
+ ciphertext: Buffer.concat([cipher.update(JSON.stringify(parseRecoveryValues(values, `${kind} recovery material`)), "utf8"), cipher.final()]).toString("base64"),
458
+ iv: iv.toString("base64"),
459
+ schemaVersion: PLATFORM_RECOVERY_ENVELOPE_VERSION,
460
+ tag: cipher.getAuthTag().toString("base64")
461
+ });
462
+ }
463
+ function recoveryAad(manifest, kind) {
464
+ return Buffer.from(`void-platform-recovery-v1\0${manifest.account.id}\0${manifest.id}\0${manifest.ownershipNonce}\0${kind}`);
465
+ }
466
+ function platformRecoveryKey(directory, create) {
467
+ const fromEnvironment = process.env.VOID_PLATFORM_RECOVERY_KEY;
468
+ if (fromEnvironment) return parseRecoveryKey(fromEnvironment, "VOID_PLATFORM_RECOVERY_KEY");
469
+ const account = `recovery:${createHash("sha256").update(resolve(directory)).digest("hex")}`;
470
+ const saved = readKeyringPassword(PLATFORM_RECOVERY_KEYRING_SERVICE, account);
471
+ if (saved) return parseRecoveryKey(saved, "system keychain recovery key");
472
+ if (!create) return null;
473
+ const generated = randomBytes(32);
474
+ if (!writeKeyringPassword(PLATFORM_RECOVERY_KEYRING_SERVICE, account, generated.toString("base64"))) throw new Error("platform: The system keychain is unavailable. Refusing to write platform secrets to disk. Configure a system keychain or set a base64-encoded 32-byte VOID_PLATFORM_RECOVERY_KEY from your secret manager.");
475
+ return generated;
476
+ }
477
+ function parseRecoveryKey(value, name) {
478
+ const key = Buffer.from(value, "base64");
479
+ if (key.byteLength !== 32 || key.toString("base64") !== value) throw new Error(`platform: ${name} must be a canonical base64-encoded 32-byte key.`);
480
+ return key;
481
+ }
482
+ function parseRecoveryEnvelope(value) {
483
+ if (!value || typeof value !== "object" || Array.isArray(value)) throw new Error("encrypted recovery envelope must be an object");
484
+ const envelope = value;
485
+ if (envelope.schemaVersion !== PLATFORM_RECOVERY_ENVELOPE_VERSION || envelope.algorithm !== "aes-256-gcm" || typeof envelope.ciphertext !== "string" || typeof envelope.iv !== "string" || typeof envelope.tag !== "string") throw new Error("encrypted recovery envelope is invalid");
486
+ if (Buffer.from(envelope.iv, "base64").byteLength !== 12) throw new Error("encrypted recovery IV is invalid");
487
+ if (Buffer.from(envelope.tag, "base64").byteLength !== 16) throw new Error("encrypted recovery tag is invalid");
488
+ return envelope;
489
+ }
490
+ function parseRecoveryValues(value, name) {
491
+ if (!value || typeof value !== "object" || Array.isArray(value)) throw new Error(`${name} must be an object`);
492
+ const entries = Object.entries(value);
493
+ if (entries.some(([, entry]) => typeof entry !== "string")) throw new Error(`${name} values must be strings`);
494
+ return Object.fromEntries(entries);
495
+ }
496
+ function removePlatformConnectionForInstallation(installationId, directory = platformRegistryDirectory()) {
497
+ withRegistryLock(directory, () => {
498
+ const current = readRegistry(directory);
499
+ const connections = current.connections.filter((connection) => connection.installationId !== installationId);
500
+ writeJsonAtomically(join(directory, "registry.json"), {
501
+ activeConnectionId: current.activeConnectionId && connections.some((connection) => connection.id === current.activeConnectionId) ? current.activeConnectionId : connections[0]?.id ?? null,
502
+ connections,
503
+ schemaVersion: 1
504
+ });
505
+ });
506
+ }
507
+ //#endregion
78
508
  //#region ../../node_modules/.pnpm/fast-string-truncated-width@3.0.3/node_modules/fast-string-truncated-width/dist/utils.js
79
509
  const getCodePointsLength = (() => {
80
510
  const SURROGATE_PAIR_RE = /[\uD800-\uDBFF][\uDC00-\uDFFF]/g;
@@ -357,7 +787,7 @@ function wrapAnsi(string, columns, options) {
357
787
  return String(string).normalize().split(CRLF_OR_LF).map((line) => exec(line, columns, options)).join("\n");
358
788
  }
359
789
  //#endregion
360
- //#region ../../node_modules/.pnpm/@clack+core@1.4.3/node_modules/@clack/core/dist/index.mjs
790
+ //#region ../../node_modules/.pnpm/@clack+core@1.5.0/node_modules/@clack/core/dist/index.mjs
361
791
  var import_src = (/* @__PURE__ */ __commonJSMin(((exports, module) => {
362
792
  const ESC = "\x1B";
363
793
  const CSI = `${ESC}[`;
@@ -438,6 +868,7 @@ const settings = {
438
868
  error: "Something went wrong"
439
869
  },
440
870
  withGuide: true,
871
+ accessible: void 0,
441
872
  date: {
442
873
  monthNames: [...[
443
874
  "January",
@@ -462,6 +893,12 @@ const settings = {
462
893
  }
463
894
  }
464
895
  };
896
+ function isAccessible(n) {
897
+ if (n !== void 0) return n;
898
+ if (settings.accessible !== void 0) return settings.accessible;
899
+ const e = process.env.ACCESSIBLE;
900
+ return e !== void 0 && e !== "" && e !== "0" && e !== "false";
901
+ }
465
902
  function isActionKey(n, e) {
466
903
  if (typeof n == "string") return settings.aliases.get(n) === e;
467
904
  for (const s of n) if (s !== void 0 && isActionKey(s, e)) return true;
@@ -489,7 +926,7 @@ function setRawMode(e, r) {
489
926
  const o = e;
490
927
  o.isTTY && o.setRawMode(r);
491
928
  }
492
- function block({ input: e = stdin, output: r = stdout, overwrite: o = true, hideCursor: t = true } = {}) {
929
+ function block({ input: e = stdin, output: r = stdout, overwrite: o = true, hideCursor: n = true } = {}) {
493
930
  const s = l.createInterface({
494
931
  input: e,
495
932
  output: r,
@@ -497,48 +934,48 @@ function block({ input: e = stdin, output: r = stdout, overwrite: o = true, hide
497
934
  tabSize: 1
498
935
  });
499
936
  l.emitKeypressEvents(e, s), e instanceof ReadStream && e.isTTY && e.setRawMode(true);
500
- const n = (f, { name: a, sequence: p }) => {
937
+ const t = (f, { name: a, sequence: w }) => {
501
938
  if (isActionKey([
502
939
  String(f),
503
940
  a,
504
- p
941
+ w
505
942
  ], "cancel")) {
506
- t && r.write(import_src.cursor.show), process.exit(0);
943
+ n && r.write(import_src.cursor.show), process.exit(0);
507
944
  return;
508
945
  }
509
946
  if (!o) return;
510
947
  const i = a === "return" ? 0 : -1, m = a === "return" ? -1 : 0;
511
948
  l.moveCursor(r, i, m, () => {
512
949
  l.clearLine(r, 1, () => {
513
- e.once("keypress", n);
950
+ e.once("keypress", t);
514
951
  });
515
952
  });
516
953
  };
517
- return t && r.write(import_src.cursor.hide), e.once("keypress", n), () => {
518
- e.off("keypress", n), t && r.write(import_src.cursor.show), e instanceof ReadStream && e.isTTY && !R && e.setRawMode(false), s.terminal = false, s.close();
954
+ return n && r.write(import_src.cursor.hide), e.once("keypress", t), () => {
955
+ e.off("keypress", t), n && r.write(import_src.cursor.show), e instanceof ReadStream && e.isTTY && !R && e.setRawMode(false), s.terminal = false, s.close();
519
956
  };
520
957
  }
521
- const getColumns = (e) => "columns" in e && typeof e.columns == "number" ? e.columns : 80, getRows = (e) => "rows" in e && typeof e.rows == "number" ? e.rows : 20;
522
- function wrapTextWithPrefix(e, r, o, t = o, s = o, n) {
958
+ const getColumns = (e) => "columns" in e && typeof e.columns == "number" ? e.columns : 80;
959
+ const getRows = (e) => "rows" in e && typeof e.rows == "number" ? e.rows : 20;
960
+ function wrapTextWithPrefix(e, r, o, n = o, s = o, t) {
523
961
  return wrapAnsi(r, getColumns(e ?? stdout) - o.length, {
524
962
  hard: true,
525
963
  trim: false
526
964
  }).split(`
527
965
  `).map((c, i, m) => {
528
- const d = n ? n(c, i) : c;
529
- return i === 0 ? `${t}${d}` : i === m.length - 1 ? `${s}${d}` : `${o}${d}`;
966
+ const d = t ? t(c, i) : c;
967
+ return i === 0 ? `${n}${d}` : i === m.length - 1 ? `${s}${d}` : `${o}${d}`;
530
968
  }).join(`
531
969
  `);
532
970
  }
533
- function runValidation(e, n) {
971
+ function runValidation(e, a) {
534
972
  if ("~standard" in e) {
535
- const a = e["~standard"].validate(n);
536
- if (a instanceof Promise) throw new TypeError("Schema validation must be synchronous. Update `validate()` and remove any asynchronous logic.");
537
- return a.issues?.at(0)?.message;
973
+ const n = e["~standard"].validate(a);
974
+ return n instanceof Promise ? n.then((r) => r.issues?.at(0)?.message) : n.issues?.at(0)?.message;
538
975
  }
539
- return e(n);
976
+ return e(a);
540
977
  }
541
- var V = class {
978
+ var y = class {
542
979
  input;
543
980
  output;
544
981
  _abortSignal;
@@ -553,9 +990,17 @@ var V = class {
553
990
  error = "";
554
991
  value;
555
992
  userInput = "";
993
+ /**
994
+ * Whether accessible (static, screen-reader friendly) output is enabled for
995
+ * this prompt, resolved from the `accessible` option, the global setting,
996
+ * and the `ACCESSIBLE` env var.
997
+ */
998
+ get accessible() {
999
+ return isAccessible(this.opts.accessible);
1000
+ }
556
1001
  constructor(t, e = true) {
557
- const { input: i = stdin, output: n = stdout, render: s, signal: r, ...o } = t;
558
- this.opts = o, this.onKeypress = this.onKeypress.bind(this), this.close = this.close.bind(this), this.render = this.render.bind(this), this._render = s.bind(this), this._track = e, this._abortSignal = r, this.input = i, this.output = n;
1002
+ const { input: i = stdin, output: s = stdout, render: r, signal: n, ...o } = t;
1003
+ this.opts = o, this.onKeypress = this.onKeypress.bind(this), this.close = this.close.bind(this), this.render = this.render.bind(this), this._render = r.bind(this), this._track = e, this._abortSignal = n, this.input = i, this.output = s;
559
1004
  }
560
1005
  /**
561
1006
  * Unsubscribe all listeners
@@ -596,9 +1041,9 @@ var V = class {
596
1041
  * @param data - The data to pass to the callback
597
1042
  */
598
1043
  emit(t, ...e) {
599
- const i = this._subscribers.get(t) ?? [], n = [];
600
- for (const s of i) s.cb(...e), s.once && n.push(() => i.splice(i.indexOf(s), 1));
601
- for (const s of n) s();
1044
+ const i = this._subscribers.get(t) ?? [], s = [];
1045
+ for (const r of i) r.cb(...e), r.once && s.push(() => i.splice(i.indexOf(r), 1));
1046
+ for (const r of s) r();
602
1047
  }
603
1048
  prompt() {
604
1049
  return new Promise((t) => {
@@ -639,22 +1084,25 @@ var V = class {
639
1084
  name: "u"
640
1085
  }), this._setUserInput("");
641
1086
  }
642
- onKeypress(t, e) {
643
- if (this._track && e.name !== "return" && (e.name && this._isActionKey(t, e) && this.rl?.write(null, {
644
- ctrl: true,
645
- name: "h"
646
- }), this._cursor = this.rl?.cursor ?? 0, this._setUserInput(this.rl?.line)), this.state === "error" && (this.state = "active"), e?.name && (!this._track && settings.aliases.has(e.name) && this.emit("cursor", settings.aliases.get(e.name)), settings.actions.has(e.name) && this.emit("cursor", e.name)), t && (t.toLowerCase() === "y" || t.toLowerCase() === "n") && this.emit("confirm", t.toLowerCase() === "y"), this.emit("key", t, e), e?.name === "return" && this._shouldSubmit(t, e)) {
647
- if (this.opts.validate) {
648
- const i = runValidation(this.opts.validate, this.value);
649
- i && (this.error = i instanceof Error ? i.message : i, this.state = "error", this.rl?.write(this.userInput));
1087
+ async onKeypress(t, e) {
1088
+ if (this.state !== "validating") {
1089
+ if (this._track && e.name !== "return" && (e.name && this._isActionKey(t, e) && this.rl?.write(null, {
1090
+ ctrl: true,
1091
+ name: "h"
1092
+ }), this._cursor = this.rl?.cursor ?? 0, this._setUserInput(this.rl?.line)), this.state === "error" && (this.state = "active"), e?.name && (!this._track && settings.aliases.has(e.name) && this.emit("cursor", settings.aliases.get(e.name)), settings.actions.has(e.name) && this.emit("cursor", e.name)), t && (t.toLowerCase() === "y" || t.toLowerCase() === "n") && this.emit("confirm", t.toLowerCase() === "y"), this.emit("key", t, e), e?.name === "return" && this._shouldSubmit(t, e)) {
1093
+ if (this.opts.validate) {
1094
+ const i = runValidation(this.opts.validate, this.value);
1095
+ let s;
1096
+ i instanceof Promise ? (this.state = "validating", this.render(), s = await i) : s = i, s && (this.error = s instanceof Error ? s.message : s, this.state = "error", this.rl?.write(this.userInput));
1097
+ }
1098
+ this.state !== "error" && (this.state = "submit");
650
1099
  }
651
- this.state !== "error" && (this.state = "submit");
1100
+ isActionKey([
1101
+ t,
1102
+ e?.name,
1103
+ e?.sequence
1104
+ ], "cancel") && (this.state = "cancel"), (this.state === "submit" || this.state === "cancel") && this.emit("finalize"), this.render(), (this.state === "submit" || this.state === "cancel") && this.close();
652
1105
  }
653
- isActionKey([
654
- t,
655
- e?.name,
656
- e?.sequence
657
- ], "cancel") && (this.state = "cancel"), (this.state === "submit" || this.state === "cancel") && this.emit("finalize"), this.render(), (this.state === "submit" || this.state === "cancel") && this.close();
658
1106
  }
659
1107
  close() {
660
1108
  this.input.unpipe(), this.input.removeListener("keypress", this.onKeypress), this.output.write(`
@@ -678,27 +1126,27 @@ var V = class {
678
1126
  else {
679
1127
  const e = diffLines(this._prevFrame, t), i = getRows(this.output);
680
1128
  if (this.restoreCursor(), e) {
681
- const n = Math.max(0, e.numLinesAfter - i), s = Math.max(0, e.numLinesBefore - i);
682
- let r = e.lines.find((o) => o >= n);
683
- if (r === void 0) {
1129
+ const s = Math.max(0, e.numLinesAfter - i), r = Math.max(0, e.numLinesBefore - i);
1130
+ let n = e.lines.find((o) => o >= s);
1131
+ if (n === void 0) {
684
1132
  this._prevFrame = t;
685
1133
  return;
686
1134
  }
687
1135
  if (e.lines.length === 1) {
688
- this.output.write(import_src.cursor.move(0, r - s)), this.output.write(import_src.erase.lines(1));
1136
+ this.output.write(import_src.cursor.move(0, n - r)), this.output.write(import_src.erase.lines(1));
689
1137
  const o = t.split(`
690
1138
  `);
691
- this.output.write(o[r]), this._prevFrame = t, this.output.write(import_src.cursor.move(0, o.length - r - 1));
1139
+ this.output.write(o[n]), this._prevFrame = t, this.output.write(import_src.cursor.move(0, o.length - n - 1));
692
1140
  return;
693
1141
  } else if (e.lines.length > 1) {
694
- if (n < s) r = n;
1142
+ if (s < r) n = s;
695
1143
  else {
696
- const h = r - s;
1144
+ const h = n - r;
697
1145
  h > 0 && this.output.write(import_src.cursor.move(0, h));
698
1146
  }
699
1147
  this.output.write(import_src.erase.down());
700
1148
  const f = t.split(`
701
- `).slice(r);
1149
+ `).slice(n);
702
1150
  this.output.write(f.join(`
703
1151
  `)), this._prevFrame = t;
704
1152
  return;
@@ -710,7 +1158,7 @@ var V = class {
710
1158
  }
711
1159
  }
712
1160
  };
713
- var r = class extends V {
1161
+ var r = class extends y {
714
1162
  get cursor() {
715
1163
  return this.value ? 0 : 1;
716
1164
  }
@@ -727,7 +1175,7 @@ var r = class extends V {
727
1175
  });
728
1176
  }
729
1177
  };
730
- let u$1 = class u extends V {
1178
+ let u$1 = class u extends y {
731
1179
  _mask = "•";
732
1180
  get cursor() {
733
1181
  return this._cursor;
@@ -753,7 +1201,7 @@ let u$1 = class u extends V {
753
1201
  });
754
1202
  }
755
1203
  };
756
- let n$1 = class n extends V {
1204
+ let n$1 = class n extends y {
757
1205
  options;
758
1206
  cursor = 0;
759
1207
  get _selectedValue() {
@@ -773,15 +1221,13 @@ let n$1 = class n extends V {
773
1221
  this.cursor = findCursor(this.cursor, -1, this.options);
774
1222
  break;
775
1223
  case "down":
776
- case "right":
777
- this.cursor = findCursor(this.cursor, 1, this.options);
778
- break;
1224
+ case "right": this.cursor = findCursor(this.cursor, 1, this.options);
779
1225
  }
780
1226
  this.changeValue();
781
1227
  });
782
1228
  }
783
1229
  };
784
- var n = class extends V {
1230
+ var n = class extends y {
785
1231
  get userInputWithCursor() {
786
1232
  if (this.state === "submit") return this.userInput;
787
1233
  const t = this.userInput;
@@ -804,7 +1250,7 @@ var n = class extends V {
804
1250
  }
805
1251
  };
806
1252
  //#endregion
807
- //#region ../../node_modules/.pnpm/@clack+prompts@1.7.0/node_modules/@clack/prompts/dist/index.mjs
1253
+ //#region ../../node_modules/.pnpm/@clack+prompts@1.8.0/node_modules/@clack/prompts/dist/index.mjs
808
1254
  var dist_exports = /* @__PURE__ */ __exportAll({
809
1255
  SELECT_INSTRUCTIONS: () => SELECT_INSTRUCTIONS,
810
1256
  S_BAR: () => S_BAR,
@@ -851,15 +1297,41 @@ function isUnicodeSupported() {
851
1297
  if (process$1.platform !== "win32") return process$1.env.TERM !== "linux";
852
1298
  return Boolean(process$1.env.CI) || Boolean(process$1.env.WT_SESSION) || Boolean(process$1.env.TERMINUS_SUBLIME) || process$1.env.ConEmuTask === "{cmd::Cmder}" || process$1.env.TERM_PROGRAM === "Terminus-Sublime" || process$1.env.TERM_PROGRAM === "vscode" || process$1.env.TERM === "xterm-256color" || process$1.env.TERM === "alacritty" || process$1.env.TERMINAL_EMULATOR === "JetBrains-JediTerm";
853
1299
  }
854
- const unicode = isUnicodeSupported(), isCI = () => process.env.CI === "true", unicodeOr = (o, e) => unicode ? o : e, S_STEP_ACTIVE = unicodeOr("◆", "*"), S_STEP_CANCEL = unicodeOr("■", "x"), S_STEP_ERROR = unicodeOr("▲", "x"), S_STEP_SUBMIT = unicodeOr("◇", "o"), S_BAR_START = unicodeOr("┌", "T"), S_BAR = unicodeOr("│", "|"), S_BAR_END = unicodeOr("└", "—"), S_RADIO_ACTIVE = unicodeOr("●", ">"), S_RADIO_INACTIVE = unicodeOr("○", " "), S_CHECKBOX_ACTIVE = unicodeOr("◻", "[•]"), S_CHECKBOX_INACTIVE = unicodeOr("◻", "[ ]"), S_PASSWORD_MASK = unicodeOr("▪", "•"), S_BAR_H = unicodeOr("─", "-"), S_CORNER_TOP_RIGHT = unicodeOr("╮", "+"), S_CONNECT_LEFT = unicodeOr("├", "+"), S_CORNER_BOTTOM_RIGHT = unicodeOr("╯", "+"), S_CORNER_BOTTOM_LEFT = unicodeOr("╰", "+"), S_INFO = unicodeOr("●", "•"), S_SUCCESS = unicodeOr("◆", "*"), S_WARN = unicodeOr("▲", "!"), S_ERROR = unicodeOr("■", "x"), symbol = (o) => {
1300
+ const unicode = isUnicodeSupported();
1301
+ const isCI = () => process.env.CI === "true";
1302
+ const unicodeOr = (o, e) => unicode ? o : e;
1303
+ const S_STEP_ACTIVE = unicodeOr("◆", "*");
1304
+ const S_STEP_CANCEL = unicodeOr("■", "x");
1305
+ const S_STEP_ERROR = unicodeOr("▲", "x");
1306
+ const S_STEP_SUBMIT = unicodeOr("◇", "o");
1307
+ const S_BAR_START = unicodeOr("┌", "T");
1308
+ const S_BAR = unicodeOr("│", "|");
1309
+ const S_BAR_END = unicodeOr("└", "—");
1310
+ const S_RADIO_ACTIVE = unicodeOr("●", ">");
1311
+ const S_RADIO_INACTIVE = unicodeOr("○", " ");
1312
+ const S_CHECKBOX_ACTIVE = unicodeOr("◻", "[•]");
1313
+ const S_CHECKBOX_INACTIVE = unicodeOr("◻", "[ ]");
1314
+ const S_PASSWORD_MASK = unicodeOr("▪", "•");
1315
+ const S_BAR_H = unicodeOr("─", "-");
1316
+ const S_CORNER_TOP_RIGHT = unicodeOr("╮", "+");
1317
+ const S_CONNECT_LEFT = unicodeOr("├", "+");
1318
+ const S_CORNER_BOTTOM_RIGHT = unicodeOr("╯", "+");
1319
+ const S_CORNER_BOTTOM_LEFT = unicodeOr("╰", "+");
1320
+ const S_INFO = unicodeOr("●", "•");
1321
+ const S_SUCCESS = unicodeOr("◆", "*");
1322
+ const S_WARN = unicodeOr("▲", "!");
1323
+ const S_ERROR = unicodeOr("■", "x");
1324
+ const symbol = (o) => {
855
1325
  switch (o) {
856
1326
  case "initial":
857
1327
  case "active": return styleText("cyan", S_STEP_ACTIVE);
858
1328
  case "cancel": return styleText("red", S_STEP_CANCEL);
859
1329
  case "error": return styleText("yellow", S_STEP_ERROR);
860
1330
  case "submit": return styleText("green", S_STEP_SUBMIT);
1331
+ case "validating": return styleText("dim", S_STEP_ACTIVE);
861
1332
  }
862
- }, symbolBar = (o) => {
1333
+ };
1334
+ const symbolBar = (o) => {
863
1335
  switch (o) {
864
1336
  case "initial":
865
1337
  case "active": return styleText("cyan", S_BAR);
@@ -1001,18 +1473,21 @@ const cancel = (o = "", t) => {
1001
1473
  i.write(`${e}${styleText("red", o)}
1002
1474
 
1003
1475
  `);
1004
- }, intro = (o = "", t) => {
1476
+ };
1477
+ const intro = (o = "", t) => {
1005
1478
  const i = t?.output ?? process.stdout, e = t?.withGuide ?? settings.withGuide ? `${styleText("gray", S_BAR_START)} ` : "";
1006
1479
  i.write(`${e}${o}
1007
1480
  `);
1008
- }, outro = (o = "", t) => {
1481
+ };
1482
+ const outro = (o = "", t) => {
1009
1483
  const i = t?.output ?? process.stdout, e = t?.withGuide ?? settings.withGuide ? `${styleText("gray", S_BAR)}
1010
1484
  ${styleText("gray", S_BAR_END)} ` : "";
1011
1485
  i.write(`${e}${o}
1012
1486
 
1013
1487
  `);
1014
1488
  };
1015
- const W$1 = (o) => o, C = (o, e, s) => {
1489
+ const W$1 = (o) => o;
1490
+ const C = (o, e, s) => {
1016
1491
  const a = {
1017
1492
  hard: true,
1018
1493
  trim: false
@@ -1200,110 +1675,48 @@ ${b}
1200
1675
  }).prompt();
1201
1676
  };
1202
1677
  `${styleText("gray", S_BAR)}`;
1203
- const text = (e) => new n({
1204
- validate: e.validate,
1205
- placeholder: e.placeholder,
1206
- defaultValue: e.defaultValue,
1207
- initialValue: e.initialValue,
1208
- output: e.output,
1209
- signal: e.signal,
1210
- input: e.input,
1678
+ const text = (t) => new n({
1679
+ validate: t.validate,
1680
+ placeholder: t.placeholder,
1681
+ defaultValue: t.defaultValue,
1682
+ initialValue: t.initialValue,
1683
+ output: t.output,
1684
+ signal: t.signal,
1685
+ input: t.input,
1211
1686
  render() {
1212
- const i = e?.withGuide ?? settings.withGuide, s = `${`${i ? `${styleText("gray", S_BAR)}
1213
- ` : ""}${symbol(this.state)} `}${e.message}
1214
- `, c = e.placeholder && e.placeholder.length > 0 ? styleText("inverse", e.placeholder[0]) + styleText("dim", e.placeholder.slice(1)) : styleText(["inverse", "hidden"], "_"), o = this.userInput ? this.userInputWithCursor : c, l = this.value ?? "";
1687
+ const r = t?.withGuide ?? settings.withGuide, l = `${`${r ? `${styleText("gray", S_BAR)}
1688
+ ` : ""}${symbol(this.state)} `}${t.message}
1689
+ `, d = t.placeholder && t.placeholder.length > 0 ? styleText("inverse", t.placeholder[0]) + styleText("dim", t.placeholder.slice(1)) : styleText(["inverse", "hidden"], "_"), o = this.userInput ? this.userInputWithCursor : d, s = this.value ?? "";
1215
1690
  switch (this.state) {
1691
+ case "validating": {
1692
+ const n = r ? `${styleText("cyan", S_BAR)} ` : "", i = r ? styleText("cyan", S_BAR_END) : "";
1693
+ return `${l}${n}${styleText("dim", o)}
1694
+ ${i} ${styleText("dim", "Validating...")}
1695
+ `;
1696
+ }
1216
1697
  case "error": {
1217
- const n = this.error ? ` ${styleText("yellow", this.error)}` : "", r = i ? `${styleText("yellow", S_BAR)} ` : "", d = i ? styleText("yellow", S_BAR_END) : "";
1218
- return `${s.trim()}
1219
- ${r}${o}
1220
- ${d}${n}
1698
+ const n = this.error ? ` ${styleText("yellow", this.error)}` : "", i = r ? `${styleText("yellow", S_BAR)} ` : "", c = r ? styleText("yellow", S_BAR_END) : "";
1699
+ return `${l.trim()}
1700
+ ${i}${o}
1701
+ ${c}${n}
1221
1702
  `;
1222
1703
  }
1223
1704
  case "submit": {
1224
- const n = l ? ` ${styleText("dim", l)}` : "";
1225
- return `${s}${i ? styleText("gray", S_BAR) : ""}${n}`;
1705
+ const n = s ? `${r ? " " : ""}${styleText("dim", s)}` : "";
1706
+ return `${l}${r ? styleText("gray", S_BAR) : ""}${n}`;
1226
1707
  }
1227
1708
  case "cancel": {
1228
- const n = l ? ` ${styleText(["strikethrough", "dim"], l)}` : "", r = i ? styleText("gray", S_BAR) : "";
1229
- return `${s}${r}${n}${l.trim() ? `
1230
- ${r}` : ""}`;
1709
+ const n = s ? ` ${styleText(["strikethrough", "dim"], s)}` : "", i = r ? styleText("gray", S_BAR) : "";
1710
+ return `${l}${i}${n}${s.trim() ? `
1711
+ ${i}` : ""}`;
1231
1712
  }
1232
- default: return `${s}${i ? `${styleText("cyan", S_BAR)} ` : ""}${o}
1233
- ${i ? styleText("cyan", S_BAR_END) : ""}
1713
+ default: return `${l}${r ? `${styleText("cyan", S_BAR)} ` : ""}${o}
1714
+ ${r ? styleText("cyan", S_BAR_END) : ""}
1234
1715
  `;
1235
1716
  }
1236
1717
  }
1237
1718
  }).prompt();
1238
1719
  //#endregion
1239
- //#region src/cli/output.ts
1240
- var import_picocolors = /* @__PURE__ */ __toESM(require_picocolors(), 1);
1241
- /**
1242
- * CI-safe spinner wrapper. In CI environments (GitHub Actions, etc.),
1243
- * `@clack/prompts` spinner emits DEC Private Mode cursor hide/show codes
1244
- * (`\x1b[?25l` / `\x1b[?25h`) that render as text artifacts. This wrapper
1245
- * replaces the spinner with plain log output in CI.
1246
- */
1247
- function createSpinner() {
1248
- if (!isCI()) return spinner();
1249
- let currentMessage = "";
1250
- return {
1251
- start(msg = "") {
1252
- currentMessage = msg;
1253
- if (msg) log.step(msg);
1254
- },
1255
- stop(msg = "") {
1256
- if (msg) log.info(msg);
1257
- },
1258
- message(msg = "") {
1259
- if (msg && msg !== currentMessage) {
1260
- currentMessage = msg;
1261
- log.step(msg);
1262
- }
1263
- },
1264
- cancel(msg = "") {
1265
- if (msg) log.warn(msg);
1266
- },
1267
- error(msg = "") {
1268
- if (msg) log.error(msg);
1269
- },
1270
- clear() {},
1271
- get isCancelled() {
1272
- return false;
1273
- }
1274
- };
1275
- }
1276
- function cliTitle(command) {
1277
- return import_picocolors.default.blue(`void ${command}`);
1278
- }
1279
- function sectionTitle(title) {
1280
- return import_picocolors.default.reset(import_picocolors.default.blue(title));
1281
- }
1282
- function categoryTitle(title) {
1283
- return import_picocolors.default.reset(import_picocolors.default.bold(import_picocolors.default.cyan(title)));
1284
- }
1285
- function dim(text) {
1286
- return import_picocolors.default.dim(text);
1287
- }
1288
- function tablePrefix() {
1289
- return `${import_picocolors.default.gray("│")} `;
1290
- }
1291
- function helpLine(command, description) {
1292
- return `${import_picocolors.default.reset(command.padEnd(34))} ${import_picocolors.default.dim(description)}`;
1293
- }
1294
- /**
1295
- * Ensure a timestamp string will be parsed as UTC by `new Date()`.
1296
- * DB timestamps lack timezone info — appends 'Z' only when no
1297
- * existing indicator (Z, z, or numeric offset) is present.
1298
- */
1299
- function ensureUtc(s) {
1300
- const last = s.at(-1);
1301
- if (last === "Z" || last === "z") return s;
1302
- if (s.includes("+", 10)) return s;
1303
- if (s.lastIndexOf("-") > 9) return s;
1304
- return s + "Z";
1305
- }
1306
- //#endregion
1307
1720
  //#region src/cli/agents.ts
1308
1721
  function getPackageDir() {
1309
1722
  let dir = join(fileURLToPath(import.meta.url), "..");
@@ -1319,136 +1732,188 @@ const agents = {
1319
1732
  "claude-code": {
1320
1733
  displayName: "Claude Code",
1321
1734
  skillsDir: ".claude/skills",
1322
- detect: (root) => existsSync(join(root, ".claude")) || existsSync(join(root, "CLAUDE.md")),
1323
- mcpConfig: [{
1324
- filePath: ".claude/settings.json",
1325
- rootKey: "mcpServers"
1326
- }, {
1327
- filePath: ".claude/settings.local.json",
1328
- rootKey: "mcpServers"
1329
- }]
1735
+ detect: (root) => existsSync(join(root, ".claude")) || existsSync(join(root, "CLAUDE.md"))
1330
1736
  },
1331
1737
  amp: {
1332
1738
  displayName: "Amp",
1333
1739
  skillsDir: ".agents/skills",
1334
- detect: (root) => existsSync(join(root, ".agents")),
1335
- mcpHint: "Run `npx void mcp` — this starts a stdio MCP server. See your agent's docs for how to add a local MCP server."
1740
+ detect: (root) => existsSync(join(root, ".agents"))
1336
1741
  },
1337
1742
  codex: {
1338
1743
  displayName: "Codex",
1339
1744
  skillsDir: ".agents/skills",
1340
- detect: (root) => existsSync(join(root, ".codex")),
1341
- mcpHint: "codex mcp add void -- npx void mcp"
1745
+ detect: (root) => existsSync(join(root, ".codex"))
1342
1746
  },
1343
1747
  cursor: {
1344
1748
  displayName: "Cursor",
1345
1749
  skillsDir: ".agents/skills",
1346
- detect: (root) => existsSync(join(root, ".cursor")),
1347
- mcpConfig: [{
1348
- filePath: ".cursor/mcp.json",
1349
- rootKey: "mcpServers"
1350
- }]
1750
+ detect: (root) => existsSync(join(root, ".cursor"))
1351
1751
  },
1352
1752
  windsurf: {
1353
1753
  displayName: "Windsurf",
1354
1754
  skillsDir: ".windsurf/skills",
1355
- detect: (root) => existsSync(join(root, ".windsurf")),
1356
- mcpConfig: [{
1357
- filePath: ".windsurf/mcp.json",
1358
- rootKey: "mcpServers"
1359
- }]
1755
+ detect: (root) => existsSync(join(root, ".windsurf"))
1360
1756
  },
1361
1757
  "gemini-cli": {
1362
1758
  displayName: "Gemini CLI",
1363
1759
  skillsDir: ".agents/skills",
1364
- detect: (root) => existsSync(join(root, ".gemini")),
1365
- mcpHint: "gemini mcp add void -- npx void mcp"
1760
+ detect: (root) => existsSync(join(root, ".gemini"))
1366
1761
  },
1367
1762
  "github-copilot": {
1368
1763
  displayName: "GitHub Copilot",
1369
1764
  skillsDir: ".agents/skills",
1370
- detect: (root) => existsSync(join(root, ".github", "copilot-instructions.md")) || existsSync(join(root, ".vscode", "mcp.json")),
1371
- mcpConfig: [{
1372
- filePath: ".vscode/mcp.json",
1373
- rootKey: "servers",
1374
- extraFields: { type: "stdio" }
1375
- }]
1765
+ detect: (root) => existsSync(join(root, ".github", "copilot-instructions.md"))
1376
1766
  },
1377
1767
  cline: {
1378
1768
  displayName: "Cline",
1379
1769
  skillsDir: ".cline/skills",
1380
- detect: (root) => existsSync(join(root, ".cline")),
1381
- mcpHint: "Run `npx void mcp` — this starts a stdio MCP server. See your agent's docs for how to add a local MCP server."
1770
+ detect: (root) => existsSync(join(root, ".cline"))
1382
1771
  },
1383
1772
  roo: {
1384
1773
  displayName: "Roo Code",
1385
1774
  skillsDir: ".roo/skills",
1386
- detect: (root) => existsSync(join(root, ".roo")),
1387
- mcpConfig: [{
1388
- filePath: ".roo/mcp.json",
1389
- rootKey: "mcpServers"
1390
- }]
1775
+ detect: (root) => existsSync(join(root, ".roo"))
1391
1776
  },
1392
1777
  kilo: {
1393
1778
  displayName: "Kilo Code",
1394
1779
  skillsDir: ".kilocode/skills",
1395
- detect: (root) => existsSync(join(root, ".kilocode")),
1396
- mcpHint: "Run `npx void mcp` — this starts a stdio MCP server. See your agent's docs for how to add a local MCP server."
1780
+ detect: (root) => existsSync(join(root, ".kilocode"))
1397
1781
  },
1398
1782
  continue: {
1399
1783
  displayName: "Continue",
1400
1784
  skillsDir: ".continue/skills",
1401
- detect: (root) => existsSync(join(root, ".continue")),
1402
- mcpHint: "Run `npx void mcp` — this starts a stdio MCP server. See your agent's docs for how to add a local MCP server."
1785
+ detect: (root) => existsSync(join(root, ".continue"))
1403
1786
  },
1404
1787
  goose: {
1405
1788
  displayName: "Goose",
1406
1789
  skillsDir: ".goose/skills",
1407
- detect: (root) => existsSync(join(root, ".goose")),
1408
- mcpHint: "Run `npx void mcp` — this starts a stdio MCP server. See your agent's docs for how to add a local MCP server."
1790
+ detect: (root) => existsSync(join(root, ".goose"))
1409
1791
  },
1410
1792
  opencode: {
1411
1793
  displayName: "OpenCode",
1412
1794
  skillsDir: ".agents/skills",
1413
- detect: (root) => existsSync(join(root, ".opencode")),
1414
- mcpHint: "Run `npx void mcp` — this starts a stdio MCP server. See your agent's docs for how to add a local MCP server."
1795
+ detect: (root) => existsSync(join(root, ".opencode"))
1415
1796
  },
1416
1797
  trae: {
1417
1798
  displayName: "Trae",
1418
1799
  skillsDir: ".trae/skills",
1419
- detect: (root) => existsSync(join(root, ".trae")),
1420
- mcpHint: "Run `npx void mcp` — this starts a stdio MCP server. See your agent's docs for how to add a local MCP server."
1800
+ detect: (root) => existsSync(join(root, ".trae"))
1421
1801
  },
1422
1802
  junie: {
1423
1803
  displayName: "Junie",
1424
1804
  skillsDir: ".junie/skills",
1425
- detect: (root) => existsSync(join(root, ".junie")),
1426
- mcpHint: "Run `npx void mcp` — this starts a stdio MCP server. See your agent's docs for how to add a local MCP server."
1805
+ detect: (root) => existsSync(join(root, ".junie"))
1427
1806
  },
1428
1807
  "kiro-cli": {
1429
1808
  displayName: "Kiro CLI",
1430
1809
  skillsDir: ".kiro/skills",
1431
- detect: (root) => existsSync(join(root, ".kiro")),
1432
- mcpHint: "Run `npx void mcp` — this starts a stdio MCP server. See your agent's docs for how to add a local MCP server."
1810
+ detect: (root) => existsSync(join(root, ".kiro"))
1433
1811
  },
1434
1812
  zencoder: {
1435
1813
  displayName: "Zencoder",
1436
1814
  skillsDir: ".zencoder/skills",
1437
- detect: (root) => existsSync(join(root, ".zencoder")),
1438
- mcpHint: "Run `npx void mcp` — this starts a stdio MCP server. See your agent's docs for how to add a local MCP server."
1815
+ detect: (root) => existsSync(join(root, ".zencoder"))
1439
1816
  },
1440
1817
  "qwen-code": {
1441
1818
  displayName: "Qwen Code",
1442
1819
  skillsDir: ".qwen/skills",
1443
- detect: (root) => existsSync(join(root, ".qwen")),
1444
- mcpHint: "Run `npx void mcp` — this starts a stdio MCP server. See your agent's docs for how to add a local MCP server."
1820
+ detect: (root) => existsSync(join(root, ".qwen"))
1445
1821
  }
1446
1822
  };
1447
- function getAgentById(id) {
1448
- return agents[id];
1449
- }
1450
1823
  function detectAgents(root) {
1451
1824
  return Object.values(agents).filter((a) => a.detect(root));
1452
1825
  }
1453
1826
  //#endregion
1454
- export { text as A, dist_exports as C, outro as D, note as E, require_picocolors as M, password as O, confirm as S, log as T, S_RADIO_ACTIVE as _, cliTitle as a, S_STEP_SUBMIT as b, ensureUtc as c, sectionTitle as d, tablePrefix as f, S_CHECKBOX_INACTIVE as g, S_CHECKBOX_ACTIVE as h, categoryTitle as i, isCancel as j, select as k, helpLine as l, S_BAR_END as m, getAgentById as n, createSpinner as o, S_BAR as p, getPackageDir as r, dim as s, detectAgents as t, import_picocolors as u, S_RADIO_INACTIVE as v, intro as w, cancel as x, S_STEP_ACTIVE as y };
1827
+ //#region src/cli/cloudflare-user-output.ts
1828
+ /**
1829
+ * Keep Void's public CLI vocabulary at the product level while preserving real
1830
+ * Cloudflare config filenames and environment variables that users may need to
1831
+ * inspect. The underlying implementation remains available in source and deploy
1832
+ * diagnostics, but normal remediation always points back to Void commands.
1833
+ */
1834
+ function formatCloudflareUserMessage(message) {
1835
+ const preserved = [];
1836
+ const protect = (value) => {
1837
+ return `\uE000VOID_CF_TERM_${preserved.push(value) - 1}\uE001`;
1838
+ };
1839
+ let result = message.replace(/(?:[A-Za-z]:)?[^\s`"']*wrangler\.jsonc?/gi, protect).replace(/\bWRANGLER_[A-Z0-9_]+\b/g, protect).replace(/\.wrangler\b/gi, protect).replace(/`wrangler deploy`/gi, "`void deploy --platform cloudflare`").replace(/`wrangler secret list[^`]*`/gi, "`void secret list`").replace(/`wrangler secret put\s+([^`]*)`/gi, "`void secret put $1`").replace(/`wrangler d1 migrations apply[^`]*`/gi, "`void db migrate --remote`").replace(/`wrangler d1 migrations list[^`]*`/gi, "`void db status`").replace(/`wrangler[^`]*`/gi, "the underlying Cloudflare operation").replace(/"wrangler[^"\n]*"/gi, "\"Cloudflare operation\"").replace(/\bwrangler uploader\b/gi, "Cloudflare deployment tool").replace(/\bwrangler (?:CLI|binary|process|child)\b/gi, "Cloudflare deployment tool").replace(/\bwrangler config\b/gi, "Cloudflare config").replace(/\bwrangler\b/gi, "Cloudflare tooling");
1840
+ result = result.replace(/\uE000VOID_CF_TERM_(\d+)\uE001/g, (_match, index) => {
1841
+ return preserved[Number(index)] ?? "";
1842
+ });
1843
+ return result;
1844
+ }
1845
+ //#endregion
1846
+ //#region src/cli/output.ts
1847
+ var import_picocolors = /* @__PURE__ */ __toESM(require_picocolors(), 1);
1848
+ /** Keep recovery commands on the same CLI when using the local checkout launcher. */
1849
+ function cliCommandName() {
1850
+ const entryName = process.argv[1]?.split(/[\\/]/).at(-1);
1851
+ return entryName === "void-dev" || entryName === "void-dev.cmd" ? "void-dev" : "void";
1852
+ }
1853
+ /**
1854
+ * CI-safe spinner wrapper. In CI environments (GitHub Actions, etc.),
1855
+ * `@clack/prompts` spinner emits DEC Private Mode cursor hide/show codes
1856
+ * (`\x1b[?25l` / `\x1b[?25h`) that render as text artifacts. This wrapper
1857
+ * replaces the spinner with plain log output in CI.
1858
+ */
1859
+ function createSpinner(options) {
1860
+ if (!isCI()) return spinner(options);
1861
+ let currentMessage = "";
1862
+ return {
1863
+ start(msg = "") {
1864
+ currentMessage = msg;
1865
+ if (msg) log.step(msg);
1866
+ },
1867
+ stop(msg = "") {
1868
+ if (msg) log.info(msg);
1869
+ },
1870
+ message(msg = "") {
1871
+ if (msg && msg !== currentMessage) {
1872
+ currentMessage = msg;
1873
+ log.step(msg);
1874
+ }
1875
+ },
1876
+ cancel(msg = "") {
1877
+ if (msg) log.warn(msg);
1878
+ },
1879
+ error(msg = "") {
1880
+ if (msg) log.error(msg);
1881
+ },
1882
+ clear() {},
1883
+ get isCancelled() {
1884
+ return false;
1885
+ }
1886
+ };
1887
+ }
1888
+ function cliTitle(command) {
1889
+ return import_picocolors.default.blue(`void ${command}`);
1890
+ }
1891
+ function sectionTitle(title) {
1892
+ return import_picocolors.default.reset(import_picocolors.default.blue(title));
1893
+ }
1894
+ function categoryTitle(title) {
1895
+ return import_picocolors.default.reset(import_picocolors.default.bold(import_picocolors.default.cyan(title)));
1896
+ }
1897
+ function dim(text) {
1898
+ return import_picocolors.default.dim(text);
1899
+ }
1900
+ function tablePrefix() {
1901
+ return `${import_picocolors.default.gray("│")} `;
1902
+ }
1903
+ function helpLine(command, description) {
1904
+ return `${import_picocolors.default.reset(command.padEnd(34))} ${import_picocolors.default.dim(description)}`;
1905
+ }
1906
+ /**
1907
+ * Ensure a timestamp string will be parsed as UTC by `new Date()`.
1908
+ * DB timestamps lack timezone info — appends 'Z' only when no
1909
+ * existing indicator (Z, z, or numeric offset) is present.
1910
+ */
1911
+ function ensureUtc(s) {
1912
+ const last = s.at(-1);
1913
+ if (last === "Z" || last === "z") return s;
1914
+ if (s.includes("+", 10)) return s;
1915
+ if (s.lastIndexOf("-") > 9) return s;
1916
+ return s + "Z";
1917
+ }
1918
+ //#endregion
1919
+ export { resolveInstallationManifest as $, password as A, assertPlatformInstallationSlugAvailable as B, cancel as C, log as D, intro as E, isCancel as F, normalizePlatformApiUrl as G, latestPlatformWorkerCutoverGeneration as H, settings as I, promoteInstallationSecrets as J, platformCredentialAccount as K, u$1 as L, symbol as M, text as N, note as O, CANCEL_SYMBOL as P, removePlatformConnectionForInstallation as Q, wrapAnsi as R, S_STEP_SUBMIT as S, dist_exports as T, listInstallationManifests as U, getActivePlatformConnection as V, listPlatformConnections as W, readPendingInstallationSecrets as X, readInstallationRecoverySecrets as Y, removeInstallationRecoverySecrets as Z, S_CHECKBOX_INACTIVE as _, dim as a, readKeyringPassword as at, S_RADIO_INACTIVE as b, import_picocolors as c, formatCloudflareUserMessage as d, savePlatformConnection as et, detectAgents as f, S_CHECKBOX_ACTIVE as g, S_BAR_END as h, createSpinner as i, deleteKeyringPassword as it, select as j, outro as k, sectionTitle as l, S_BAR as m, cliCommandName as n, writeInstallationManifest as nt, ensureUtc as o, writeKeyringPassword as ot, getPackageDir as p, platformWorkerSecretUpdateIntentState as q, cliTitle as r, writePendingInstallationSecrets as rt, helpLine as s, require_picocolors as st, categoryTitle as t, selectPlatformConnection as tt, tablePrefix as u, S_PASSWORD_MASK as v, confirm as w, S_STEP_ACTIVE as x, S_RADIO_ACTIVE as y, acquirePlatformLifecycleLock as z };