gemi 0.51.1 → 0.53.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (211) hide show
  1. package/dist/app/index.js +1 -1
  2. package/dist/bin/gemi.js +30 -1
  3. package/dist/bin/gemi.js.map +4 -4
  4. package/dist/broadcasting/index.js +1 -1
  5. package/dist/bun/plugin.js +1 -1
  6. package/dist/bun/preload.js +1 -1
  7. package/dist/{chunk-npeq63a2.js → chunk-07jtzbf0.js} +1 -1
  8. package/dist/{chunk-5v36t9j3.js → chunk-092pj2j2.js} +3 -3
  9. package/dist/{chunk-5v36t9j3.js.map → chunk-092pj2j2.js.map} +1 -1
  10. package/dist/{chunk-zwpx6z5f.js → chunk-0h3jr9d9.js} +2 -2
  11. package/dist/{chunk-8zd6d5nd.js.map → chunk-0h3jr9d9.js.map} +1 -1
  12. package/dist/{chunk-hwwp6x2s.js → chunk-1ab1ptq5.js} +2 -2
  13. package/dist/{chunk-hwwp6x2s.js.map → chunk-1ab1ptq5.js.map} +1 -1
  14. package/dist/chunk-1pqfmw5h.js +5 -0
  15. package/dist/chunk-1pqfmw5h.js.map +30 -0
  16. package/dist/{chunk-dk01r6se.js → chunk-23g7qdpg.js} +2 -2
  17. package/dist/{chunk-dk01r6se.js.map → chunk-23g7qdpg.js.map} +1 -1
  18. package/dist/{chunk-fs091xz7.js → chunk-2gw6cyyj.js} +2 -2
  19. package/dist/{chunk-fs091xz7.js.map → chunk-2gw6cyyj.js.map} +1 -1
  20. package/dist/chunk-2qn472j4.js +5 -0
  21. package/dist/{chunk-8gb1w19q.js.map → chunk-2qn472j4.js.map} +1 -1
  22. package/dist/{chunk-pkzj7c5w.js → chunk-2sfz64xh.js} +2 -2
  23. package/dist/{chunk-pkzj7c5w.js.map → chunk-2sfz64xh.js.map} +1 -1
  24. package/dist/{chunk-q0xq0pt0.js → chunk-2yth3kk2.js} +4 -4
  25. package/dist/{chunk-q0xq0pt0.js.map → chunk-2yth3kk2.js.map} +1 -1
  26. package/dist/chunk-3d3nmr5g.js +4 -0
  27. package/dist/{chunk-6x6gb7zg.js.map → chunk-3d3nmr5g.js.map} +3 -3
  28. package/dist/{chunk-8vnbvfmd.js → chunk-3y9nf09k.js} +2 -2
  29. package/dist/{chunk-8vnbvfmd.js.map → chunk-3y9nf09k.js.map} +1 -1
  30. package/dist/{chunk-8zd6d5nd.js → chunk-4e61qbp4.js} +2 -2
  31. package/dist/{chunk-zwpx6z5f.js.map → chunk-4e61qbp4.js.map} +1 -1
  32. package/dist/{chunk-j33n723q.js → chunk-5s45prj5.js} +3 -3
  33. package/dist/{chunk-j33n723q.js.map → chunk-5s45prj5.js.map} +1 -1
  34. package/dist/{chunk-16bnbtyn.js → chunk-68w225rv.js} +2 -2
  35. package/dist/{chunk-16bnbtyn.js.map → chunk-68w225rv.js.map} +1 -1
  36. package/dist/{chunk-rxeyhwqz.js → chunk-69w4egkg.js} +3 -3
  37. package/dist/{chunk-rxeyhwqz.js.map → chunk-69w4egkg.js.map} +1 -1
  38. package/dist/{chunk-8m3wq94b.js → chunk-6scjrbw7.js} +2 -2
  39. package/dist/{chunk-8m3wq94b.js.map → chunk-6scjrbw7.js.map} +1 -1
  40. package/dist/{chunk-3z4nwzvp.js → chunk-7s1g3v1y.js} +3 -3
  41. package/dist/{chunk-3z4nwzvp.js.map → chunk-7s1g3v1y.js.map} +1 -1
  42. package/dist/{chunk-asgfqcwd.js → chunk-88pq4gmf.js} +2 -2
  43. package/dist/{chunk-asgfqcwd.js.map → chunk-88pq4gmf.js.map} +1 -1
  44. package/dist/{chunk-p0z35s59.js → chunk-8p6rqegw.js} +1 -1
  45. package/dist/chunk-92793zh4.js +5 -0
  46. package/dist/{chunk-98sj7tkf.js.map → chunk-92793zh4.js.map} +3 -4
  47. package/dist/chunk-9279y4af.js +5 -0
  48. package/dist/{chunk-tqbp8550.js.map → chunk-9279y4af.js.map} +2 -2
  49. package/dist/chunk-bq4w14a6.js +5 -0
  50. package/dist/chunk-bq4w14a6.js.map +10 -0
  51. package/dist/{chunk-nbx9mgmr.js → chunk-cg53h5ht.js} +2 -2
  52. package/dist/{chunk-nbx9mgmr.js.map → chunk-cg53h5ht.js.map} +1 -1
  53. package/dist/{chunk-g4gjn481.js → chunk-cmq5t8p9.js} +3 -3
  54. package/dist/{chunk-g4gjn481.js.map → chunk-cmq5t8p9.js.map} +1 -1
  55. package/dist/{chunk-zznpmnp7.js → chunk-d1ahbza9.js} +3 -3
  56. package/dist/{chunk-zznpmnp7.js.map → chunk-d1ahbza9.js.map} +1 -1
  57. package/dist/{chunk-c4r1zh9q.js → chunk-ear03axe.js} +24 -24
  58. package/dist/{chunk-c4r1zh9q.js.map → chunk-ear03axe.js.map} +3 -5
  59. package/dist/{chunk-an6nq9yd.js → chunk-ebcgdv00.js} +3 -3
  60. package/dist/{chunk-an6nq9yd.js.map → chunk-ebcgdv00.js.map} +1 -1
  61. package/dist/{chunk-gvf1d636.js → chunk-faa987e4.js} +2 -2
  62. package/dist/{chunk-gvf1d636.js.map → chunk-faa987e4.js.map} +1 -1
  63. package/dist/{chunk-gdegb5t0.js → chunk-fbp5vapa.js} +2 -2
  64. package/dist/{chunk-gdegb5t0.js.map → chunk-fbp5vapa.js.map} +2 -2
  65. package/dist/chunk-ffre1z8s.js +6 -0
  66. package/dist/{chunk-y0wg8aq9.js.map → chunk-ffre1z8s.js.map} +2 -2
  67. package/dist/{chunk-6wm9bsz9.js → chunk-h5g05qwb.js} +2 -2
  68. package/dist/{chunk-6wm9bsz9.js.map → chunk-h5g05qwb.js.map} +1 -1
  69. package/dist/{chunk-x80n922n.js → chunk-h7jv3ame.js} +2 -2
  70. package/dist/{chunk-x80n922n.js.map → chunk-h7jv3ame.js.map} +1 -1
  71. package/dist/chunk-ha7n1c94.js +7 -0
  72. package/dist/{chunk-bm6q0q1q.js.map → chunk-ha7n1c94.js.map} +3 -3
  73. package/dist/{chunk-3fcgg506.js → chunk-j1knf8gv.js} +3 -3
  74. package/dist/{chunk-3fcgg506.js.map → chunk-j1knf8gv.js.map} +1 -1
  75. package/dist/{chunk-1sbm38g3.js → chunk-kaxvw75w.js} +3 -3
  76. package/dist/{chunk-1sbm38g3.js.map → chunk-kaxvw75w.js.map} +1 -1
  77. package/dist/{chunk-eyvtf769.js → chunk-kxzwem3g.js} +2 -2
  78. package/dist/{chunk-eyvtf769.js.map → chunk-kxzwem3g.js.map} +1 -1
  79. package/dist/{chunk-hnw1jy86.js → chunk-msz8rngs.js} +2 -2
  80. package/dist/{chunk-hnw1jy86.js.map → chunk-msz8rngs.js.map} +1 -1
  81. package/dist/chunk-mt2755rs.js +5 -0
  82. package/dist/{chunk-g0w87jtw.js.map → chunk-mt2755rs.js.map} +4 -3
  83. package/dist/chunk-p22rkf1g.js +8 -0
  84. package/dist/chunk-p22rkf1g.js.map +11 -0
  85. package/dist/{chunk-kv8p4h79.js → chunk-q09mmr05.js} +3 -3
  86. package/dist/{chunk-kv8p4h79.js.map → chunk-q09mmr05.js.map} +1 -1
  87. package/dist/{chunk-mrf9tjev.js → chunk-qjnv2rkh.js} +2 -2
  88. package/dist/{chunk-mrf9tjev.js.map → chunk-qjnv2rkh.js.map} +1 -1
  89. package/dist/{chunk-d3tf618w.js → chunk-qx6sahe0.js} +2 -2
  90. package/dist/{chunk-d3tf618w.js.map → chunk-qx6sahe0.js.map} +1 -1
  91. package/dist/{chunk-w7fpm2pw.js → chunk-qyaqg07q.js} +2 -2
  92. package/dist/{chunk-w7fpm2pw.js.map → chunk-qyaqg07q.js.map} +1 -1
  93. package/dist/{chunk-a6w4tpwz.js → chunk-rq770c71.js} +2 -2
  94. package/dist/{chunk-a6w4tpwz.js.map → chunk-rq770c71.js.map} +1 -1
  95. package/dist/{chunk-zezdm4ep.js → chunk-t4n25km9.js} +3 -3
  96. package/dist/{chunk-zezdm4ep.js.map → chunk-t4n25km9.js.map} +1 -1
  97. package/dist/{chunk-eby61053.js → chunk-tkv6cw94.js} +3 -3
  98. package/dist/{chunk-eby61053.js.map → chunk-tkv6cw94.js.map} +1 -1
  99. package/dist/chunk-tmk4zfz9.js +33 -0
  100. package/dist/chunk-tmk4zfz9.js.map +18 -0
  101. package/dist/{chunk-k4mjcvsm.js → chunk-ttzkn1qd.js} +2 -2
  102. package/dist/{chunk-k4mjcvsm.js.map → chunk-ttzkn1qd.js.map} +1 -1
  103. package/dist/{chunk-94k8pjmf.js → chunk-tztqkat2.js} +3 -3
  104. package/dist/{chunk-94k8pjmf.js.map → chunk-tztqkat2.js.map} +1 -1
  105. package/dist/{chunk-ybqftmjx.js → chunk-vnjvd82s.js} +2 -2
  106. package/dist/{chunk-ybqftmjx.js.map → chunk-vnjvd82s.js.map} +1 -1
  107. package/dist/{chunk-0k5jhyry.js → chunk-xsmt86n3.js} +2 -2
  108. package/dist/{chunk-0k5jhyry.js.map → chunk-xsmt86n3.js.map} +1 -1
  109. package/dist/chunk-y4djde42.js +5 -0
  110. package/dist/chunk-y4djde42.js.map +11 -0
  111. package/dist/{chunk-ntr81h76.js → chunk-z4q1ty6w.js} +2 -2
  112. package/dist/{chunk-ntr81h76.js.map → chunk-z4q1ty6w.js.map} +1 -1
  113. package/dist/{chunk-53w1njqz.js → chunk-zhsaz9cr.js} +1 -1
  114. package/dist/chunks/ThemeProvider-CTX9LOFC.js +2718 -0
  115. package/dist/chunks/ThemeProvider-CTX9LOFC.js.map +1 -0
  116. package/dist/client/Mutation.d.ts +1 -1
  117. package/dist/client/Mutation.d.ts.map +1 -1
  118. package/dist/client/ThemeProvider.d.ts +7 -0
  119. package/dist/client/ThemeProvider.d.ts.map +1 -1
  120. package/dist/client/index.js +107 -2673
  121. package/dist/client/index.js.map +1 -1
  122. package/dist/client/useIsNavigationPending.d.ts.map +1 -1
  123. package/dist/client/useMutate.d.ts.map +1 -1
  124. package/dist/config/index.js +1 -1
  125. package/dist/console/Command.d.ts +143 -0
  126. package/dist/console/Command.d.ts.map +1 -0
  127. package/dist/console/CommandRegistry.d.ts +46 -0
  128. package/dist/console/CommandRegistry.d.ts.map +1 -0
  129. package/dist/console/builder.d.ts +115 -0
  130. package/dist/console/builder.d.ts.map +1 -0
  131. package/dist/console/builder.test-d.d.ts +2 -0
  132. package/dist/console/builder.test-d.d.ts.map +1 -0
  133. package/dist/console/config.d.ts +40 -0
  134. package/dist/console/config.d.ts.map +1 -0
  135. package/dist/console/context.d.ts +90 -0
  136. package/dist/console/context.d.ts.map +1 -0
  137. package/dist/console/errors.d.ts +19 -0
  138. package/dist/console/errors.d.ts.map +1 -0
  139. package/dist/console/parse.d.ts +65 -0
  140. package/dist/console/parse.d.ts.map +1 -0
  141. package/dist/console/run.d.ts +2 -0
  142. package/dist/console/run.d.ts.map +1 -0
  143. package/dist/console/run.js +16 -0
  144. package/dist/console/run.js.map +14 -0
  145. package/dist/console/runner.d.ts +41 -0
  146. package/dist/console/runner.d.ts.map +1 -0
  147. package/dist/console/usage.d.ts +7 -0
  148. package/dist/console/usage.d.ts.map +1 -0
  149. package/dist/container/index.js +2 -2
  150. package/dist/container/index.js.map +1 -1
  151. package/dist/database/index.js +2 -2
  152. package/dist/database/index.js.map +1 -1
  153. package/dist/email/index.js +2 -2
  154. package/dist/email/index.js.map +2 -2
  155. package/dist/facades/index.js +2 -2
  156. package/dist/facades/index.js.map +1 -1
  157. package/dist/foundation/index.js +2 -2
  158. package/dist/foundation/index.js.map +1 -1
  159. package/dist/http/ViewRouter.d.ts.map +1 -1
  160. package/dist/http/index.js +2 -2
  161. package/dist/http/index.js.map +1 -1
  162. package/dist/i18n/Dictionary.d.ts.map +1 -1
  163. package/dist/i18n/index.js +2 -2
  164. package/dist/i18n/index.js.map +3 -3
  165. package/dist/kernel/Kernel.d.ts +29 -0
  166. package/dist/kernel/Kernel.d.ts.map +1 -1
  167. package/dist/kernel/index.js +3 -3
  168. package/dist/kernel/index.js.map +3 -3
  169. package/dist/orm/index.js +2 -2
  170. package/dist/orm/index.js.map +1 -1
  171. package/dist/server/index.js +2 -2
  172. package/dist/server/index.js.map +1 -1
  173. package/dist/services/cron/ScheduleServiceProvider.d.ts.map +1 -1
  174. package/dist/services/discovery.d.ts +15 -0
  175. package/dist/services/discovery.d.ts.map +1 -1
  176. package/dist/services/index.d.ts +8 -1
  177. package/dist/services/index.d.ts.map +1 -1
  178. package/dist/services/index.js +11 -11
  179. package/dist/services/index.js.map +2 -2
  180. package/dist/support/Service.d.ts +90 -0
  181. package/dist/support/Service.d.ts.map +1 -0
  182. package/dist/support/discover.d.ts +9 -1
  183. package/dist/support/discover.d.ts.map +1 -1
  184. package/dist/support/index.d.ts +1 -0
  185. package/dist/support/index.d.ts.map +1 -1
  186. package/dist/support/index.js +2 -2
  187. package/dist/support/index.js.map +4 -3
  188. package/dist/testing/Page.d.ts +166 -0
  189. package/dist/testing/Page.d.ts.map +1 -0
  190. package/dist/testing/index.d.ts +3 -0
  191. package/dist/testing/index.d.ts.map +1 -0
  192. package/dist/testing/index.js +352 -0
  193. package/dist/testing/index.js.map +1 -0
  194. package/dist/utils/Subject.d.ts.map +1 -1
  195. package/dist/utils/variantKey.d.ts +19 -0
  196. package/dist/utils/variantKey.d.ts.map +1 -0
  197. package/package.json +3 -1
  198. package/dist/chunk-6fym5bfg.js +0 -23
  199. package/dist/chunk-6fym5bfg.js.map +0 -36
  200. package/dist/chunk-6x6gb7zg.js +0 -4
  201. package/dist/chunk-8gb1w19q.js +0 -5
  202. package/dist/chunk-98sj7tkf.js +0 -5
  203. package/dist/chunk-bm6q0q1q.js +0 -7
  204. package/dist/chunk-g0w87jtw.js +0 -5
  205. package/dist/chunk-j4rkk01q.js +0 -5
  206. package/dist/chunk-j4rkk01q.js.map +0 -10
  207. package/dist/chunk-tqbp8550.js +0 -5
  208. package/dist/chunk-y0wg8aq9.js +0 -6
  209. /package/dist/{chunk-npeq63a2.js.map → chunk-07jtzbf0.js.map} +0 -0
  210. /package/dist/{chunk-p0z35s59.js.map → chunk-8p6rqegw.js.map} +0 -0
  211. /package/dist/{chunk-53w1njqz.js.map → chunk-zhsaz9cr.js.map} +0 -0
@@ -0,0 +1,14 @@
1
+ {
2
+ "version": 3,
3
+ "sources": ["../console/context.ts", "../console/runner.ts", "../console/parse.ts", "../console/usage.ts", "../console/run.ts"],
4
+ "sourcesContent": [
5
+ "import { CommandFailed } from \"./Command\";\n\n/**\n * The single argument a command handler receives.\n *\n * ### Why the output helpers live here and not on `this`\n *\n * The authoring surface is a builder terminating in `.handle(fn)`, and `fn` is\n * an arrow function with no useful `this`. That turns out to be the better\n * arrangement rather than a cost to work around: the helpers are destructured on\n * the first line of the handler, so a reader sees which streams a command writes\n * to before reading any of it, and a test supplies its own writers by passing a\n * context instead of subclassing.\n *\n * ### Why there are three of them\n *\n * The load-bearing thing a framework can own here is **stream discipline, not\n * colour**. A diagnostic printed to stdout is what breaks\n * `TOTAL=$(gemi run count-users)` and what makes a CI grep match a progress line\n * instead of the answer, and that mistake is invisible until somebody pipes the\n * command somewhere.\n *\n * So: `line` is the command's answer and goes to stdout, `error` is a diagnostic\n * and goes to stderr, and `fail` ends the command. Deliberately absent are\n * `info`/`success` (`line` with a colour, and colour is the application's\n * business), `warn` (identical to `error`; two names for one stream is a coin\n * flip at every call site), and tables or progress bars — a console formatting\n * library is a project, not a feature.\n */\nexport interface CommandContext<\n A = Record<string, unknown>,\n O = Record<string, unknown>,\n> {\n /** The positional arguments, by the names `.arg()` declared. */\n args: A;\n\n /** The flags, by the names `.option()` declared. */\n options: O;\n\n /**\n * Everything after the command name, unparsed.\n *\n * The escape hatch, for a command that wants to forward its tail to something\n * else. Present even when parsing succeeded, so a command never has to choose\n * between the declared schema and the raw truth.\n */\n argv: readonly string[];\n\n /** The command's answer, on stdout. */\n line(message?: string): void;\n\n /** A diagnostic, on stderr. Does not end the command. */\n error(message: string): void;\n\n /**\n * Ends the command with a message and an exit code, and no stack.\n *\n * Throws rather than returning, so it type-checks as the last statement of any\n * branch and a caller cannot forget to `return` after it.\n */\n fail(message: string, code?: number): never;\n}\n\n/** Where a context writes. Injectable so tests can capture without spawning. */\nexport interface CommandWriters {\n stdout: (chunk: string) => void;\n stderr: (chunk: string) => void;\n}\n\n/**\n * Writers onto this process's streams, and the means to know they landed.\n *\n * ### Why `flush` exists\n *\n * `process.stdout.write` is asynchronous when stdout is a pipe, and `gemi run`\n * ends in an explicit `process.exit` — which it must, or a command holding a\n * database pool open would finish its work and then sit there. Those two facts\n * together truncate output at the pipe buffer: measured on Bun 1.3.14, a\n * 2,000,000-byte write followed immediately by `process.exit(0)` delivers\n * exactly 65,536 bytes through a pipe, and exits 0 while doing it. So\n * `gemi run export-users | gzip > out.gz` silently stores a fragment — the exact\n * idiom the three-stream design above exists to protect.\n *\n * The fence is the *last* write's completion callback. Chunks are flushed in\n * order, so awaiting the newest one awaits all of them. The obvious alternatives\n * do not work here: a zero-length `write(\"\", cb)` used as a fence delivered only\n * 1,310,720 of those bytes, and `writableLength` reports 0 while data is still\n * pending, so a drain loop exits immediately. Both were measured rather than\n * assumed.\n */\nexport interface ProcessWriters extends CommandWriters {\n /** Resolves once everything written so far has reached the OS. */\n flush(): Promise<void>;\n}\n\nexport function processWriters(): ProcessWriters {\n // One per stream: the last write issued to it, resolved when that write (and\n // therefore every write queued before it) has been handed over.\n let stdout: Promise<void> = Promise.resolve();\n let stderr: Promise<void> = Promise.resolve();\n\n const write = (stream: NodeJS.WriteStream, chunk: string): Promise<void> =>\n new Promise((resolve) => {\n // Resolved on the callback rather than on the return value: `write`\n // returning false means \"buffered\", not \"failed\", and an error here is\n // still a completed attempt — a closed pipe must not hang the exit.\n stream.write(chunk, () => resolve());\n });\n\n return {\n stdout: (chunk) => {\n stdout = write(process.stdout, chunk);\n },\n stderr: (chunk) => {\n stderr = write(process.stderr, chunk);\n },\n flush: async () => {\n await Promise.all([stdout, stderr]);\n },\n };\n}\n\nexport function createContext<A, O>(params: {\n args: A;\n options: O;\n argv: readonly string[];\n writers?: CommandWriters;\n}): CommandContext<A, O> {\n const writers = params.writers ?? processWriters();\n\n return {\n args: params.args,\n options: params.options,\n argv: params.argv,\n line: (message = \"\") => writers.stdout(`${message}\\n`),\n error: (message: string) => writers.stderr(`${message}\\n`),\n fail: (message: string, code = 1) => {\n throw new CommandFailed(message, code);\n },\n };\n}\n",
6
+ "import path from \"node:path\";\n\nimport type { Kernel } from \"../kernel/Kernel\";\nimport { discoverCommands } from \"../services/discovery\";\nimport { DiscoveryError } from \"../support/discover\";\nimport { withDefaults } from \"../support/withDefaults\";\nimport { CommandFailed, type CommandClass } from \"./Command\";\nimport { CommandRegistry } from \"./CommandRegistry\";\nimport { commandConfigDefaults, type CommandConfig } from \"./config\";\nimport { createContext, processWriters, type CommandWriters } from \"./context\";\nimport { ConsoleError } from \"./errors\";\nimport { parseArgv } from \"./parse\";\nimport { renderList, renderUsage } from \"./usage\";\n\nexport { ConsoleError };\n\n/**\n * `gemi run`, from the inside.\n *\n * This runs in a Bun process the CLI spawned, not in the CLI. That is the whole\n * reason the file exists, and it is worth stating here because everything below\n * assumes it:\n *\n * - `dist/bin/gemi.js` bundles its own copy of gemi, while the application's\n * Kernel resolves `gemi/*` to source. Discovery decides membership by\n * walking the prototype chain, so a `Command` base imported into the CLI\n * bundle is a *different class object* from the one `app/commands/*.ts`\n * extends — every command would be invisible, silently. In this process\n * there is one copy and the question does not arise.\n * - `--preload gemi/bun/preload` and the app's own `app/preload.ts` can only\n * be registered at process start, and a command that touches a controller\n * needs the first while the template's models need the second.\n * - Bun fixes its JSX transform and react-dom's export conditions from\n * `NODE_ENV` at startup, so a command that renders an email is only correct\n * in a process that began with the right one.\n *\n * ### Why the ordering below is the ordering\n *\n * Listing commands, reporting an unknown name and printing `--help` all resolve\n * *before* `waitForBoot()`. Those are the three things an operator does most\n * often and the three that need nothing from the application beyond its config,\n * so none of them should open a database connection. Running a command needs the\n * full boot and takes it.\n */\n\nexport interface RunConsoleParams {\n rootDir: string;\n /** The command to run. Absent means \"list what there is\". */\n name?: string;\n /** Everything after the name, exactly as it was typed — including any `--`. */\n argv: readonly string[];\n writers?: CommandWriters;\n}\n\nexport async function runConsole(params: RunConsoleParams): Promise<number> {\n const writers = params.writers ?? processWriters();\n const out = (message: string) => writers.stdout(`${message}\\n`);\n const err = (message: string) => writers.stderr(`${message}\\n`);\n\n let kernel: Kernel | undefined;\n // Hoisted only so the catch can name the command in an exit-code complaint.\n let running: CommandClass | undefined;\n\n try {\n kernel = await loadKernel(params.rootDir);\n kernel.boot();\n\n const slice = kernel.app.config.get<CommandConfig>(\"command\", {});\n const dir = withDefaults(commandConfigDefaults(), slice).commandsDir;\n\n // Resolved against `rootDir` rather than left for `discoverCommands` to hang\n // off `projectRoot()`. In the spawned process the two are the same thing —\n // the CLI spawns with no `cwd`, so the child inherits the project root — but\n // \"the same thing in production\" is how a parameter quietly stops being one.\n // This function already resolves the Kernel against `rootDir`, and a caller\n // that passes a directory only for half of it to be honoured is the kind of\n // thing tests find and nothing else does.\n const commandsDir = path.isAbsolute(dir)\n ? dir\n : path.join(params.rootDir, dir);\n\n // Declared wins, and `[]` is declared. Read before `withDefaults`, which\n // collapses absent and `undefined` into the default `[]` — the same value an\n // app writes when it means \"none, and I mean it\".\n const declared = slice.commands !== undefined;\n const commands = declared\n ? slice.commands!\n : await discoverCommands(commandsDir);\n\n const registry = new CommandRegistry(commands);\n const source = { declared, dir };\n\n if (params.name === undefined) {\n out(renderList(registry.commands, source));\n return 0;\n }\n\n const command = registry.get(params.name);\n running = command;\n\n if (!command) {\n const suggestions = registry.suggest(params.name);\n err(\n `No command named \\`${params.name}\\`.` +\n (suggestions.length > 0\n ? ` Did you mean ${suggestions\n .map((candidate) => `\\`${candidate}\\``)\n .join(\", or \")}?`\n : \"\"),\n );\n err(\"\");\n err(renderList(registry.commands, source));\n return 1;\n }\n\n const spec = {\n commandName: command.commandName,\n args: command.args,\n options: command.options,\n };\n\n const parsed = parseArgv(spec, params.argv);\n\n // Before the error branch, so `--help` works on the invocation that most\n // needs it: the one that is already a usage error. And *from the parse*\n // rather than from a token scan, because only the parse knows that the\n // `--help` in `--message --help` is a value — see `ParseResult[\"help\"]`.\n if (parsed.help) {\n out(renderUsage(command));\n return 0;\n }\n\n // `=== false` rather than `!parsed.ok`: the package compiles with\n // `strictNullChecks` off, and under it a `!x.ok` test does not narrow a\n // discriminated union while an explicit comparison does. The negation\n // compiles to the same check and reads the same, which is exactly why it is\n // worth a line — it fails as a type error here, but the same shape in an\n // untypechecked file would just quietly be `any`.\n if (parsed.ok === false) {\n for (const message of parsed.errors) err(message);\n err(\"\");\n err(renderUsage(command));\n return 1;\n }\n\n // Only now. Everything above answered a question about the application's\n // shape; this is the first line that needs the application itself.\n await kernel.waitForBoot();\n\n const context = createContext({\n args: parsed.args,\n options: parsed.options,\n argv: params.argv,\n writers,\n });\n\n const result = await kernel.run(() =>\n Promise.resolve(\n new (command as new () => { run(ctx: unknown): unknown })().run(\n context,\n ),\n ),\n );\n\n return exitCodeFor(result, command, err);\n } catch (error) {\n // A `CommandFailed`, a `ConsoleError` or a `DiscoveryError` is a sentence\n // written for this moment; anything else is a bug and keeps its stack. The\n // same split `bin/gemi.ts` already applies to `CheckModelsError`.\n //\n // `DiscoveryError` belongs in this list rather than the other because every\n // way of raising one — a command file that will not import, a builder chain\n // that was never finished — is a mistake in the application's own source\n // with the fix named in the message. A stack above it points at this\n // runner's frames, which is not where anybody needs to look.\n if (error instanceof CommandFailed) {\n err(error.message);\n\n // Through the same guard a returned value gets. `fail` takes the same\n // kind of number and the same kind of expression produces it, so\n // ``ctx.fail(`${bad.length} rows failed`, bad.length)`` with 256 bad rows\n // handed 256 straight to `process.exit`, which the shell reports as\n // status **0** — a failed command read as a success by the `&&` chain or\n // CI step waiting on it. 300 arrives as 44; 512 is 0 again.\n return exitCodeFor(error.code, running, err, \"called fail() with\");\n }\n\n if (error instanceof ConsoleError || error instanceof DiscoveryError) {\n err(error.message);\n return 1;\n }\n\n err(String((error as Error)?.stack ?? error));\n return 1;\n } finally {\n // Stops the Scheduler if it was resolved, flushes the container, clears the\n // static instance and disables the kernel context. The caller still exits\n // explicitly — see `run.ts`.\n kernel?.destroy();\n }\n}\n\nasync function loadKernel(rootDir: string): Promise<Kernel> {\n const kernelPath = path.resolve(rootDir, \"app/kernel/Kernel.ts\");\n\n let module: { default?: new () => Kernel };\n try {\n module = await import(kernelPath);\n } catch (error) {\n throw new ConsoleError(\n `Could not load ${kernelPath}:\\n ${(error as Error).message}\\n` +\n `\\`gemi run\\` boots your application the way the server does, so it ` +\n `needs the Kernel. Run it from the root of a gemi project.`,\n { cause: error },\n );\n }\n\n if (typeof module.default !== \"function\") {\n throw new ConsoleError(\n `${kernelPath} has no default export. gemi expects the Kernel subclass ` +\n `to be the default export of that file.`,\n );\n }\n\n return new module.default();\n}\n\n/**\n * What the command asked the shell to see, if a shell can actually see it.\n *\n * An exit status is one byte. Anything else a handler offers is reported rather\n * than coerced, because coercion here is silent and inverts the answer: `return\n * users.length` after 300 backfilled users would exit 44 (300 & 255), and 256\n * would exit **0** — a failure indistinguishable from success to the `&&` chain,\n * CI step or cron wrapper waiting on it.\n *\n * Both ways a command names its status come through here — `return n` and\n * `ctx.fail(msg, n)` — because both take the same kind of number from the same\n * kind of expression, and a guard on only one of them is a guard on neither.\n */\nfunction exitCodeFor(\n result: unknown,\n command: CommandClass | undefined,\n err: (message: string) => void,\n source = \"returned\",\n): number {\n if (result === undefined || result === null) return 0;\n\n if (\n typeof result === \"number\" &&\n Number.isInteger(result) &&\n result >= 0 &&\n result <= 255\n ) {\n return result;\n }\n\n const subject = command ? `Command \"${command.commandName}\"` : \"The command\";\n\n err(\n `${subject} ${source} ${JSON.stringify(result)}, which is not an exit ` +\n `code — an exit code is an integer from 0 to 255. Treating this as a ` +\n `failure.`,\n );\n return 1;\n}\n",
7
+ "import type { CommandArgument, CommandOption } from \"./Command\";\n\n/**\n * Turning what an operator typed into what a handler declared it wanted.\n *\n * A pure function over `(spec, argv)`, deliberately: this is where every\n * off-by-one in argument handling lives, and a pure function is one a test can\n * exercise a hundred ways without a project on disk, a spawned process or a\n * booted container. `runner.ts` does the parts that need those.\n *\n * ### Why gemi parses this itself instead of handing it to commander\n *\n * commander is a dependency of this package and would resolve here, and an\n * earlier draft used it. Two things argued it back out. The schema is already\n * declared — named options with a `type`, not commander's `\"-t, --tries <n>\"`\n * flag strings — so using commander means translating one declaration into\n * another and then translating its output back, with the type information lost\n * in the middle. And commander is currently a *CLI-side* concern: `bin/gemi.ts`\n * uses it, and nothing that runs inside an application does. Keeping it that way\n * means a command's parsing has no dependency at all, which matters more here\n * than it looks — this code runs in the application's process, next to the\n * application's own module graph.\n *\n * `usage.ts` renders `--help` from the same spec this reads, so the help and the\n * parser cannot drift.\n */\n\n/** `dryRun` -> `dry-run`. What the operator types. */\nexport function kebab(name: string): string {\n return name\n .replace(/([a-z0-9])([A-Z])/g, \"$1-$2\")\n .replace(/([A-Z])([A-Z][a-z])/g, \"$1-$2\")\n .toLowerCase();\n}\n\nexport interface CommandSpec {\n commandName: string;\n args: CommandArgument[];\n options: CommandOption[];\n}\n\nexport type ParseResult = {\n /**\n * The invocation asked for help rather than for work.\n *\n * Reported by the parse rather than by a separate scan, because whether a\n * `--help` is a request for help or the *value* of the option before it is a\n * question only something tracking option arity can answer. A flat token scan\n * reads `--message --help` as a request for help, prints usage and exits 0 —\n * so the message is never sent and a cron wrapper branching on the exit code\n * records a success for work that did not happen.\n *\n * Present on both branches, and the runner checks it first: `--help` has to\n * work on an invocation that would otherwise be a usage error, which is\n * precisely when somebody reaches for it.\n */\n help: boolean;\n} & (\n | {\n ok: true;\n args: Record<string, string | string[] | undefined>;\n options: Record<string, string | number | boolean | undefined>;\n }\n | { ok: false; errors: string[] }\n);\n\nfunction optionIndex(options: CommandOption[]) {\n const byName = new Map<string, CommandOption>();\n const byAlias = new Map<string, CommandOption>();\n\n for (const option of options) {\n // Both spellings resolve, so `--dryRun` works for anyone who typed the\n // declared name out of habit. The kebab form is the documented one.\n byName.set(kebab(option.name), option);\n byName.set(option.name, option);\n const alias = \"alias\" in option ? option.alias : undefined;\n if (alias) byAlias.set(alias, option);\n }\n\n return { byName, byAlias };\n}\n\n/**\n * Whether this invocation is asking for help rather than running.\n *\n * A thin read of the parse, so the two cannot disagree about what counts as a\n * `--help`. See `ParseResult[\"help\"]` for why that question needs a parse at all.\n */\nexport function wantsHelp(spec: CommandSpec, argv: readonly string[]): boolean {\n return parseArgv(spec, argv).help;\n}\n\n/**\n * Whether a token is the next option rather than the previous one's value.\n *\n * `--message --dry-run` should not set `message` to the literal `\"--dry-run\"`\n * and leave `dryRun` false — a dry run that executes for real is the worst shape\n * a parser bug can take. So a value-taking option refuses an option-shaped\n * token and says how to override it.\n *\n * The two exceptions are both real values that happen to start with a dash: a\n * negative number, and a bare `-` (the long-standing spelling of \"stdin\"). For\n * anything else `--opt=value` is the escape hatch, which is how every getopt\n * since the 1980s has handled it.\n */\nfunction looksLikeAnotherOption(token: string): boolean {\n if (token === \"--\") return true;\n if (!token.startsWith(\"-\")) return false;\n if (token === \"-\") return false;\n if (/^-(\\d|\\.\\d)/.test(token)) return false;\n return true;\n}\n\nexport function parseArgv(\n spec: CommandSpec,\n argv: readonly string[],\n): ParseResult {\n const { byName, byAlias } = optionIndex(spec.options);\n const errors: string[] = [];\n const positionals: string[] = [];\n const raw = new Map<string, string | boolean>();\n\n // Split, rather than one guard over both. A command that declares an option\n // called `help` has claimed `--help`, and a command that declares a `-h` alias\n // has claimed `-h` — but neither claims the other, and treating them as one\n // switch means a `.option(\"host\", { alias: \"h\" })` silently removes the long\n // `--help` the command never asked for, while `usage.ts` goes on advertising\n // it. The application's schema wins over the framework's convenience, exactly\n // as far as the application actually reached.\n const helpIsFree = !byName.has(\"help\");\n const shortHelpIsFree = !byAlias.has(\"h\");\n let requested = false;\n\n // Set when the token refused as a value was itself a `--help`, which is the\n // one case where \"did they want help?\" has no honest answer. See the note\n // above the return.\n let ambiguous = false;\n\n const unknown = (token: string) =>\n errors.push(`Unknown option ${token} for command \"${spec.commandName}\".`);\n\n const needsValue = (label: string, next: string | undefined) => {\n if (next === \"--help\" || next === \"-h\") ambiguous = true;\n\n errors.push(\n next === undefined\n ? `Option ${label} needs a value.`\n : `Option ${label} needs a value, but the next token is ` +\n `${JSON.stringify(next)}, which is another option. If that really is ` +\n `the value, write ${label}=${next}.`,\n );\n };\n\n let index = 0;\n while (index < argv.length) {\n const token = argv[index]!;\n\n // Everything after a bare `--` is positional, however it is spelled. This is\n // the escape hatch for an argument that looks like a flag.\n if (token === \"--\") {\n positionals.push(...argv.slice(index + 1));\n break;\n }\n\n if (token.startsWith(\"--\")) {\n const body = token.slice(2);\n const equals = body.indexOf(\"=\");\n const key = equals === -1 ? body : body.slice(0, equals);\n const inline = equals === -1 ? undefined : body.slice(equals + 1);\n\n let option = byName.get(key);\n let negated = false;\n\n // `--no-dry-run` only when there is no option actually called that.\n if (!option && key.startsWith(\"no-\")) {\n const positive = byName.get(key.slice(3));\n if (positive && positive.type === \"boolean\") {\n option = positive;\n negated = true;\n }\n }\n\n // Only once the command's own options have had their chance at the name.\n if (!option && key === \"help\" && helpIsFree) {\n requested = true;\n index += 1;\n continue;\n }\n\n if (!option) {\n unknown(`--${key}`);\n index += 1;\n continue;\n }\n\n if (option.type === \"boolean\") {\n if (inline !== undefined && inline !== \"true\" && inline !== \"false\") {\n errors.push(\n `Option --${kebab(option.name)} is a flag and takes no value, ` +\n `but got ${JSON.stringify(inline)}.`,\n );\n } else {\n const value = inline === undefined ? true : inline === \"true\";\n raw.set(option.name, negated ? !value : value);\n }\n index += 1;\n continue;\n }\n\n if (inline !== undefined) {\n raw.set(option.name, inline);\n index += 1;\n continue;\n }\n\n const next = argv[index + 1];\n if (next === undefined || looksLikeAnotherOption(next)) {\n needsValue(`--${kebab(option.name)}`, next);\n index += 1;\n continue;\n }\n\n raw.set(option.name, next);\n index += 2;\n continue;\n }\n\n if (token.startsWith(\"-\") && token.length > 1) {\n // A cluster: every character is an alias. All but the last must be flags,\n // and the last may take the remainder of the token as its value (`-l50`,\n // `-l=50`) or the next argument.\n const chars = token.slice(1);\n let consumedNext = false;\n\n for (let position = 0; position < chars.length; position += 1) {\n const option = byAlias.get(chars[position]!);\n if (!option) {\n if (chars[position] === \"h\" && shortHelpIsFree) {\n requested = true;\n continue;\n }\n unknown(`-${chars[position]}`);\n break;\n }\n\n if (option.type === \"boolean\") {\n raw.set(option.name, true);\n continue;\n }\n\n const rest = chars.slice(position + 1);\n const inline = rest.startsWith(\"=\") ? rest.slice(1) : rest;\n if (inline !== \"\") {\n raw.set(option.name, inline);\n break;\n }\n\n const next = argv[index + 1];\n if (next === undefined || looksLikeAnotherOption(next)) {\n needsValue(`-${option.alias}`, next);\n break;\n }\n\n raw.set(option.name, next);\n consumedNext = true;\n break;\n }\n\n index += consumedNext ? 2 : 1;\n continue;\n }\n\n positionals.push(token);\n index += 1;\n }\n\n const args: Record<string, string | string[] | undefined> = {};\n let cursor = 0;\n\n for (const declared of spec.args) {\n if (declared.variadic) {\n const collected = positionals.slice(cursor);\n cursor = positionals.length;\n args[declared.name] = collected;\n\n // `required` on a variadic means \"at least one\", and honouring it is the\n // only reading that matches what the operator is shown: `usage.ts` prints\n // `<files...>` for this declaration, which says mandatory. Ignoring it\n // meant `gemi run import-files` with the paths forgotten booted the\n // application, ran the handler over an empty list and exited 0 — a no-op\n // that reads as a successful import.\n if (declared.required && collected.length === 0) {\n errors.push(\n `Missing required argument <${declared.name}...>. Command ` +\n `\"${spec.commandName}\" needs at least one.`,\n );\n }\n continue;\n }\n\n const value = positionals[cursor];\n cursor += 1;\n\n if (value !== undefined) {\n args[declared.name] = value;\n continue;\n }\n\n if (declared.default !== undefined) {\n args[declared.name] = declared.default;\n continue;\n }\n\n if (declared.required) {\n errors.push(`Missing required argument <${declared.name}>.`);\n }\n\n args[declared.name] = undefined;\n }\n\n if (cursor < positionals.length) {\n const extra = positionals.slice(cursor);\n errors.push(\n `Unexpected argument${extra.length === 1 ? \"\" : \"s\"} ` +\n `${extra.map((value) => JSON.stringify(value)).join(\", \")}. ` +\n `Command \"${spec.commandName}\" takes ${spec.args.length} argument` +\n `${spec.args.length === 1 ? \"\" : \"s\"}.`,\n );\n }\n\n const options: Record<string, string | number | boolean | undefined> = {};\n\n for (const declared of spec.options) {\n const supplied = raw.get(declared.name);\n\n if (declared.type === \"boolean\") {\n options[declared.name] =\n supplied === undefined\n ? (declared.default ?? false)\n : Boolean(supplied);\n continue;\n }\n\n if (supplied === undefined) {\n if (declared.default !== undefined) {\n options[declared.name] = declared.default;\n } else if (declared.required) {\n errors.push(`Missing required option --${kebab(declared.name)}.`);\n options[declared.name] = undefined;\n } else {\n options[declared.name] = undefined;\n }\n continue;\n }\n\n const value = String(supplied);\n\n if (declared.type === \"number\") {\n const parsed = Number(value);\n // `Number(\"\")` is 0 and `Number(\" \")` is 0, which is how a typo becomes a\n // plausible-looking number. Reject anything that was not written as one.\n if (value.trim() === \"\" || !Number.isFinite(parsed)) {\n errors.push(\n `Option --${kebab(declared.name)} expects a number, but got ` +\n `${JSON.stringify(value)}.`,\n );\n options[declared.name] = undefined;\n } else {\n options[declared.name] = parsed;\n }\n continue;\n }\n\n options[declared.name] = value;\n }\n\n /**\n * A `--help` refused as a value is not a request for help.\n *\n * `gemi run notify --message --help` has two readings and no way to tell them\n * apart: the operator wanted the usage, or they wanted to send the literal\n * text `--help` and the shell ate their quotes. Answering either one silently\n * is how the reviewer's case goes wrong — showing usage and exiting 0 means\n * the notification was never sent and the wrapper waiting on the status\n * records a success.\n *\n * So the ambiguity is reported instead. `needsValue` has already written the\n * sentence naming both readings and the fix (`--message=--help`), and\n * suppressing the help request here is what lets the operator see it rather\n * than a usage screen with no explanation.\n *\n * Help still wins over an ordinary usage error — `gemi run deploy --help`\n * with `<env>` missing prints the usage, because that is the invocation\n * somebody reaches for `--help` on.\n */\n const help = requested && !ambiguous;\n\n if (errors.length > 0) return { ok: false, help, errors };\n return { ok: true, help, args, options };\n}\n",
8
+ "import type { CommandClass } from \"./Command\";\nimport { kebab } from \"./parse\";\n\n/**\n * Everything `gemi run` prints when it is not running a command.\n *\n * Rendered from the same statics `parse.ts` reads, so the help cannot describe a\n * flag the parser does not accept. That is the only reason this is not a set of\n * template literals next to the code that needs them.\n */\n\nfunction pad(entries: Array<[string, string]>, indent = \" \"): string[] {\n const width = entries.reduce((max, [left]) => Math.max(max, left.length), 0);\n return entries.map(([left, right]) =>\n right === \"\"\n ? `${indent}${left}`\n : `${indent}${left.padEnd(width)} ${right}`,\n );\n}\n\nfunction argSlot(arg: {\n name: string;\n required?: boolean;\n variadic?: boolean;\n}): string {\n const inner = arg.variadic ? `${arg.name}...` : arg.name;\n return arg.required ? `<${inner}>` : `[${inner}]`;\n}\n\n/**\n * The `--help` line, listed only in the spellings the command left free.\n *\n * `parse.ts` yields `--help` to a command that declares an option called `help`\n * and `-h` to one that declares that alias, independently. Printing an\n * unconditional `-h, --help` meant a command with a `-h, --host` was shown two\n * contradictory `-h` entries, one of which did nothing — help that lies about\n * the parser is worse than no help line at all.\n */\nfunction helpEntry(command: CommandClass): Array<[string, string]> {\n const claimed = (\n predicate: (option: CommandClass[\"options\"][number]) => boolean,\n ) => command.options.some(predicate);\n\n const longTaken = claimed(\n (option) => option.name === \"help\" || kebab(option.name) === \"help\",\n );\n const shortTaken = claimed(\n (option) => \"alias\" in option && option.alias === \"h\",\n );\n\n if (longTaken && shortTaken) return [];\n if (longTaken) return [[\"-h\", \"Show this message\"]];\n\n return [[`${shortTaken ? \"\" : \"-h, \"}--help`, \"Show this message\"]];\n}\n\nexport function renderUsage(command: CommandClass): string {\n const lines: string[] = [];\n\n const slots = command.args.map(argSlot).join(\" \");\n const usage = [\n \"gemi run\",\n command.commandName,\n command.options.length > 0 ? \"[options]\" : \"\",\n slots,\n ]\n .filter(Boolean)\n .join(\" \");\n\n lines.push(`Usage: ${usage}`);\n\n if (command.description) {\n lines.push(\"\", command.description);\n }\n\n if (command.args.length > 0) {\n lines.push(\"\", \"Arguments:\");\n lines.push(\n ...pad(\n command.args.map((arg) => {\n const notes = [\n arg.description ?? \"\",\n arg.default !== undefined\n ? `(default: ${JSON.stringify(arg.default)})`\n : \"\",\n ]\n .filter(Boolean)\n .join(\" \");\n return [argSlot(arg), notes] as [string, string];\n }),\n ),\n );\n }\n\n lines.push(\"\", \"Options:\");\n lines.push(\n ...pad([\n ...command.options.map((option) => {\n const alias =\n \"alias\" in option && option.alias ? `-${option.alias}, ` : \"\";\n const value = option.type === \"boolean\" ? \"\" : ` <${option.type}>`;\n const notes = [\n option.description ?? \"\",\n option.default !== undefined\n ? `(default: ${JSON.stringify(option.default)})`\n : \"\",\n \"required\" in option && option.required ? \"(required)\" : \"\",\n ]\n .filter(Boolean)\n .join(\" \");\n return [`${alias}--${kebab(option.name)}${value}`, notes] as [\n string,\n string,\n ];\n }),\n ...helpEntry(command),\n ]),\n );\n\n return lines.join(\"\\n\");\n}\n\nexport function renderList(\n commands: CommandClass[],\n source: { declared: boolean; dir: string },\n): string {\n const heading = source.declared\n ? `${commands.length} command${commands.length === 1 ? \"\" : \"s\"} declared in app/config/command.ts:`\n : `Commands in ${source.dir}:`;\n\n if (commands.length === 0) {\n return source.declared\n ? `app/config/command.ts declares no commands.\\n\\n` +\n `Remove the \\`commands\\` key from that slice to discover the classes ` +\n `under ${source.dir} instead — a declared list wins, and an empty one ` +\n `means \"none, and I mean it\".`\n : `No commands found in ${source.dir}.\\n\\n` +\n `A command is registered by existing: write a file there that exports ` +\n `a \\`defineCommand(...).handle(...)\\` chain and it will appear here.`;\n }\n\n const sorted = [...commands].sort((a, b) =>\n a.commandName < b.commandName ? -1 : a.commandName > b.commandName ? 1 : 0,\n );\n\n return [\n heading,\n \"\",\n ...pad(\n sorted.map(\n (command) =>\n [command.commandName, command.description] as [string, string],\n ),\n ),\n \"\",\n \"Run one with `gemi run <name>`, and see its arguments with \" +\n \"`gemi run <name> --help`.\",\n ].join(\"\\n\");\n}\n",
9
+ "/**\n * The entry point `gemi run` spawns.\n *\n * Exposed through the exports map as `gemi/console/run` and resolved by the CLI\n * out of the *application's* `node_modules`, the same way `dev` and `start`\n * resolve `gemi/bun/preload`. That indirection is the point: the runner has to\n * be the application's copy of gemi, not the one bundled into `dist/bin/gemi.js`\n * — see the note at the top of `runner.ts`.\n *\n * Nothing but argv handling lives here, so that everything worth testing lives\n * in `runConsole`, which returns an exit code instead of taking one.\n */\nimport { processWriters } from \"./context\";\nimport { runConsole } from \"./runner\";\n\n// The tail is forwarded exactly as commander handed it over, `--` and all.\n// commander passes a `--` through as a literal operand (verified: `gemi run x --\n// --weird` arrives as `[\"--\", \"--weird\"]`), and `parse.ts` already treats a `--`\n// as \"everything after this is positional\". Stripping it here — which an earlier\n// draft did — consumed the escape hatch before the only thing that reads it,\n// leaving `-- --weird` reported as an unknown option and `-- --` the only way to\n// pass a flag-shaped value.\nconst [name, ...argv] = process.argv.slice(2);\n\nconst writers = processWriters();\n\n// `.then` rather than a top-level `await`, so this file typechecks under the\n// package's inherited `module: NodeNext` — the same TS1309 that keeps `bun/` out\n// of tsconfig.json's `include`. Bun runs it as ESM either way; this just avoids\n// buying a nested tsconfig for two lines.\nrunConsole({ rootDir: process.cwd(), name, argv, writers }).then(\n async (code) => {\n // Everything written has to reach the OS before the exit below discards it —\n // see `processWriters` for what that costs when it is skipped.\n await writers.flush();\n\n // Explicit, and not belt-and-braces. `kernel.destroy()` stops the scheduler,\n // but an open database pool, a Redis client or an unref'd timer will happily\n // hold the loop open after the work is done — a command that finishes and then\n // sits there, which is the failure `kernel/exit.test.ts` exists for and the\n // one `orm/context.test.ts` names by example.\n process.exit(code);\n },\n);\n"
10
+ ],
11
+ "mappings": ";qTA+FO,IAAS,JAAc,HAAmB,JAG/C,DAAI,HAAwB,QAAQ,QAAQ,EACxC,EAAwB,QAAQ,QAAQ,EAEtC,EAAQ,CAAC,EAA4B,IACzC,IAAI,QAAQ,CAAC,IAAY,CAIvB,EAAO,MAAM,EAAO,IAAM,EAAQ,CAAC,EACpC,EAEH,MAAO,CACL,OAAQ,CAAC,IAAU,CACjB,EAAS,EAAM,QAAQ,OAAQ,CAAK,G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,SAAS,CAAW,CAClB,EACA,EACA,EACA,EAAS,WACD,CACR,GAAI,IAAW,QAAa,IAAW,KAAM,MAAO,GAEpD,GACE,OAAO,IAAW,UAClB,OAAO,UAAU,CAAM,GACvB,GAAU,GACV,GAAU,IAEV,OAAO,EAGT,IAAM,EAAU,EAAU,YAAY,EAAQ,eAAiB,cAO/D,OALA,EACE,GAAG,KAAW,KAAU,KAAK,UAAU,CAAM,2BAC3C,4EACA,UACJ,EACO,EGlPT,IAAO,KAAS,GAAQ,QAAQ,KAAK,MAAM,CAAC,EAEtC,EAAU,EAAe,EAM/B,EAAW,CAAE,QAAS,QAAQ,IAAI,EAAG,OAAM,OAAM,SAAQ,CAAC,EAAE,KAC1D,MAAO,IAAS,CAGd,MAAM,EAAQ,MAAM,EAOpB,QAAQ,KAAK,CAAI,EAErB",
12
+ "debugId": "3A559D4973E0E24564756E2164756E21",
13
+ "names": []
14
+ }
@@ -0,0 +1,41 @@
1
+ import { type CommandWriters } from "./context";
2
+ import { ConsoleError } from "./errors";
3
+ export { ConsoleError };
4
+ /**
5
+ * `gemi run`, from the inside.
6
+ *
7
+ * This runs in a Bun process the CLI spawned, not in the CLI. That is the whole
8
+ * reason the file exists, and it is worth stating here because everything below
9
+ * assumes it:
10
+ *
11
+ * - `dist/bin/gemi.js` bundles its own copy of gemi, while the application's
12
+ * Kernel resolves `gemi/*` to source. Discovery decides membership by
13
+ * walking the prototype chain, so a `Command` base imported into the CLI
14
+ * bundle is a *different class object* from the one `app/commands/*.ts`
15
+ * extends — every command would be invisible, silently. In this process
16
+ * there is one copy and the question does not arise.
17
+ * - `--preload gemi/bun/preload` and the app's own `app/preload.ts` can only
18
+ * be registered at process start, and a command that touches a controller
19
+ * needs the first while the template's models need the second.
20
+ * - Bun fixes its JSX transform and react-dom's export conditions from
21
+ * `NODE_ENV` at startup, so a command that renders an email is only correct
22
+ * in a process that began with the right one.
23
+ *
24
+ * ### Why the ordering below is the ordering
25
+ *
26
+ * Listing commands, reporting an unknown name and printing `--help` all resolve
27
+ * *before* `waitForBoot()`. Those are the three things an operator does most
28
+ * often and the three that need nothing from the application beyond its config,
29
+ * so none of them should open a database connection. Running a command needs the
30
+ * full boot and takes it.
31
+ */
32
+ export interface RunConsoleParams {
33
+ rootDir: string;
34
+ /** The command to run. Absent means "list what there is". */
35
+ name?: string;
36
+ /** Everything after the name, exactly as it was typed — including any `--`. */
37
+ argv: readonly string[];
38
+ writers?: CommandWriters;
39
+ }
40
+ export declare function runConsole(params: RunConsoleParams): Promise<number>;
41
+ //# sourceMappingURL=runner.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"runner.d.ts","sourceRoot":"","sources":["../../console/runner.ts"],"names":[],"mappings":"AASA,OAAO,EAAiC,KAAK,cAAc,EAAE,MAAM,WAAW,CAAC;AAC/E,OAAO,EAAE,YAAY,EAAE,MAAM,UAAU,CAAC;AAIxC,OAAO,EAAE,YAAY,EAAE,CAAC;AAExB;;;;;;;;;;;;;;;;;;;;;;;;;;;GA2BG;AAEH,MAAM,WAAW,gBAAgB;IAC/B,OAAO,EAAE,MAAM,CAAC;IAChB,6DAA6D;IAC7D,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,+EAA+E;IAC/E,IAAI,EAAE,SAAS,MAAM,EAAE,CAAC;IACxB,OAAO,CAAC,EAAE,cAAc,CAAC;CAC1B;AAED,wBAAsB,UAAU,CAAC,MAAM,EAAE,gBAAgB,GAAG,OAAO,CAAC,MAAM,CAAC,CAkJ1E"}
@@ -0,0 +1,7 @@
1
+ import type { CommandClass } from "./Command";
2
+ export declare function renderUsage(command: CommandClass): string;
3
+ export declare function renderList(commands: CommandClass[], source: {
4
+ declared: boolean;
5
+ dir: string;
6
+ }): string;
7
+ //# sourceMappingURL=usage.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"usage.d.ts","sourceRoot":"","sources":["../../console/usage.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,WAAW,CAAC;AAwD9C,wBAAgB,WAAW,CAAC,OAAO,EAAE,YAAY,GAAG,MAAM,CAgEzD;AAED,wBAAgB,UAAU,CACxB,QAAQ,EAAE,YAAY,EAAE,EACxB,MAAM,EAAE;IAAE,QAAQ,EAAE,OAAO,CAAC;IAAC,GAAG,EAAE,MAAM,CAAA;CAAE,GACzC,MAAM,CAiCR"}
@@ -1,4 +1,4 @@
1
1
  // @bun
2
- import{Ee as e,Fe as o}from"../chunk-w7fpm2pw.js";import"../chunk-zwpx6z5f.js";export{o as Container,e as BindingResolutionError};
2
+ import{Ne as e,Oe as o}from"../chunk-qyaqg07q.js";import"../chunk-0h3jr9d9.js";export{o as Container,e as BindingResolutionError};
3
3
 
4
- //# debugId=560AA97C59F8AEB664756E2164756E21
4
+ //# debugId=60644B238DFF089964756E2164756E21
@@ -4,6 +4,6 @@
4
4
  "sourcesContent": [
5
5
  ],
6
6
  "mappings": "",
7
- "debugId": "560AA97C59F8AEB664756E2164756E21",
7
+ "debugId": "60644B238DFF089964756E2164756E21",
8
8
  "names": []
9
9
  }
@@ -1,4 +1,4 @@
1
1
  // @bun
2
- import{p as b}from"../chunk-mrf9tjev.js";import"../chunk-k4mjcvsm.js";import{Ac as a,Bc as t,Cc as i,Dc as s,Ec as C,Fc as f,Gc as D,Hc as c,Ic as p,wc as e,xc as o,yc as r,zc as n}from"../chunk-eby61053.js";import"../chunk-nbx9mgmr.js";import"../chunk-8vnbvfmd.js";import"../chunk-zwpx6z5f.js";export{n as isSqlite,a as isMysqlFamily,r as inferDialect,c as defineDatabaseConfig,p as databaseConfigDefaults,e as UnknownDatabaseUrlError,i as UnknownConnectionError,s as ReservedConnectionNameError,o as MissingDatabaseUrlError,b as DatabaseServiceProvider,D as DatabaseManager,t as DEFAULT_CONNECTION,C as CrossConnectionTransactionError,f as Connection};
2
+ import{p as b}from"../chunk-qjnv2rkh.js";import"../chunk-ttzkn1qd.js";import{Cc as e,Dc as o,Ec as r,Fc as n,Gc as a,Hc as t,Ic as i,Jc as s,Kc as C,Lc as f,Mc as D,Nc as c,Oc as p}from"../chunk-tkv6cw94.js";import"../chunk-cg53h5ht.js";import"../chunk-3y9nf09k.js";import"../chunk-0h3jr9d9.js";export{n as isSqlite,a as isMysqlFamily,r as inferDialect,c as defineDatabaseConfig,p as databaseConfigDefaults,e as UnknownDatabaseUrlError,i as UnknownConnectionError,s as ReservedConnectionNameError,o as MissingDatabaseUrlError,b as DatabaseServiceProvider,D as DatabaseManager,t as DEFAULT_CONNECTION,C as CrossConnectionTransactionError,f as Connection};
3
3
 
4
- //# debugId=E31D0DA0C19DBF5764756E2164756E21
4
+ //# debugId=FF7E217A7DC0FB5D64756E2164756E21
@@ -4,6 +4,6 @@
4
4
  "sourcesContent": [
5
5
  ],
6
6
  "mappings": "",
7
- "debugId": "E31D0DA0C19DBF5764756E2164756E21",
7
+ "debugId": "FF7E217A7DC0FB5D64756E2164756E21",
8
8
  "names": []
9
9
  }
@@ -1,5 +1,5 @@
1
1
  // @bun
2
- import{ze as o}from"../chunk-g4gjn481.js";import{Ae as p}from"../chunk-asgfqcwd.js";import{De as f}from"../chunk-g0w87jtw.js";import"../chunk-w7fpm2pw.js";import"../chunk-j4rkk01q.js";import"../chunk-zwpx6z5f.js";import{render as i}from"jsx-email";import I from"process";import{Buffer as a}from"buffer";import d from"path";import{fileURLToPath as kT}from"url";import{promisify as FT}from"util";import r from"child_process";import WT,{constants as IT}from"fs/promises";import u from"process";import c,{constants as JT}from"fs/promises";import b from"process";import GT from"os";import _ from"fs";import RT from"fs";import y from"fs";var j;function ET(){try{return y.statSync("/.dockerenv"),!0}catch{return!1}}function $T(){try{return y.readFileSync("/proc/self/cgroup","utf8").includes("docker")}catch{return!1}}function L(){if(j===void 0)j=ET()||$T();return j}var O,qT=()=>{try{return RT.statSync("/run/.containerenv"),!0}catch{return!1}};function Y(){if(O===void 0)O=qT()||L();return O}var B=()=>{if(b.platform!=="linux")return!1;if(GT.release().toLowerCase().includes("microsoft")){if(Y())return!1;return!0}try{if(_.readFileSync("/proc/version","utf8").toLowerCase().includes("microsoft"))return!Y()}catch{}if(_.existsSync("/proc/sys/fs/binfmt_misc/WSLInterop")||_.existsSync("/run/WSL"))return!Y();return!1},Q=b.env.__IS_WSL_TEST__?B:B();var KT=(()=>{let S;return async function(){if(S)return S;let v="/etc/wsl.conf",$=!1;try{await c.access(v,JT.F_OK),$=!0}catch{}if(!$)return"/mnt/";let E=await c.readFile(v,{encoding:"utf8"}),q=/(?<!#.*)root\s*=\s*(?<mountPoint>.*)/g.exec(E);if(!q)return"/mnt/";return S=q.groups.mountPoint.trim(),S=S.endsWith("/")?S:`${S}/`,S}})(),QT=async()=>{return`${await KT()}c/Windows/System32/WindowsPowerShell/v1.0/powershell.exe`},x=async()=>{if(Q)return QT();return`${u.env.SYSTEMROOT||u.env.windir||String.raw`C:\Windows`}\\System32\\WindowsPowerShell\\v1.0\\powershell.exe`};function V(T,S,v){let $=(E)=>Object.defineProperty(T,S,{value:E,enumerable:!0,writable:!0});return Object.defineProperty(T,S,{configurable:!0,enumerable:!0,get(){let E=v();return $(E),E},set(E){$(E)}}),T}import{promisify as _T}from"util";import F from"process";import{execFile as xT}from"child_process";import{promisify as VT}from"util";import YT from"process";import{execFile as ZT}from"child_process";var HT=VT(ZT);async function D(){if(YT.platform!=="darwin")throw Error("macOS only");let{stdout:T}=await HT("defaults",["read","com.apple.LaunchServices/com.apple.launchservices.secure","LSHandlers"]),v=/LSHandlerRoleAll = "(?!-)(?<id>[^"]+?)";\s+?LSHandlerURLScheme = (?:http|https);/.exec(T)?.groups.id??"com.apple.Safari";if(v==="com.apple.safari")return"com.apple.Safari";return v}import MT from"process";import{promisify as NT}from"util";import{execFile as UT,execFileSync as ES}from"child_process";var XT=NT(UT);async function A(T,{humanReadableOutput:S=!0,signal:v}={}){if(MT.platform!=="darwin")throw Error("macOS only");let $=S?[]:["-ss"],E={};if(v)E.signal=v;let{stdout:q}=await XT("osascript",["-e",T,$],E);return q.trim()}async function z(T){return A(`tell application "Finder" to set app_path to application file id "${T}" as string
2
+ import{He as o}from"../chunk-cmq5t8p9.js";import{Ie as p}from"../chunk-88pq4gmf.js";import{Me as f}from"../chunk-mt2755rs.js";import"../chunk-qyaqg07q.js";import"../chunk-0h3jr9d9.js";import{render as i}from"jsx-email";import I from"process";import{Buffer as a}from"buffer";import d from"path";import{fileURLToPath as kT}from"url";import{promisify as FT}from"util";import r from"child_process";import WT,{constants as IT}from"fs/promises";import u from"process";import c,{constants as JT}from"fs/promises";import b from"process";import GT from"os";import _ from"fs";import RT from"fs";import y from"fs";var j;function ET(){try{return y.statSync("/.dockerenv"),!0}catch{return!1}}function $T(){try{return y.readFileSync("/proc/self/cgroup","utf8").includes("docker")}catch{return!1}}function L(){if(j===void 0)j=ET()||$T();return j}var O,qT=()=>{try{return RT.statSync("/run/.containerenv"),!0}catch{return!1}};function Y(){if(O===void 0)O=qT()||L();return O}var B=()=>{if(b.platform!=="linux")return!1;if(GT.release().toLowerCase().includes("microsoft")){if(Y())return!1;return!0}try{if(_.readFileSync("/proc/version","utf8").toLowerCase().includes("microsoft"))return!Y()}catch{}if(_.existsSync("/proc/sys/fs/binfmt_misc/WSLInterop")||_.existsSync("/run/WSL"))return!Y();return!1},Q=b.env.__IS_WSL_TEST__?B:B();var KT=(()=>{let S;return async function(){if(S)return S;let v="/etc/wsl.conf",$=!1;try{await c.access(v,JT.F_OK),$=!0}catch{}if(!$)return"/mnt/";let E=await c.readFile(v,{encoding:"utf8"}),q=/(?<!#.*)root\s*=\s*(?<mountPoint>.*)/g.exec(E);if(!q)return"/mnt/";return S=q.groups.mountPoint.trim(),S=S.endsWith("/")?S:`${S}/`,S}})(),QT=async()=>{return`${await KT()}c/Windows/System32/WindowsPowerShell/v1.0/powershell.exe`},x=async()=>{if(Q)return QT();return`${u.env.SYSTEMROOT||u.env.windir||String.raw`C:\Windows`}\\System32\\WindowsPowerShell\\v1.0\\powershell.exe`};function V(T,S,v){let $=(E)=>Object.defineProperty(T,S,{value:E,enumerable:!0,writable:!0});return Object.defineProperty(T,S,{configurable:!0,enumerable:!0,get(){let E=v();return $(E),E},set(E){$(E)}}),T}import{promisify as _T}from"util";import F from"process";import{execFile as xT}from"child_process";import{promisify as VT}from"util";import YT from"process";import{execFile as ZT}from"child_process";var HT=VT(ZT);async function D(){if(YT.platform!=="darwin")throw Error("macOS only");let{stdout:T}=await HT("defaults",["read","com.apple.LaunchServices/com.apple.launchservices.secure","LSHandlers"]),v=/LSHandlerRoleAll = "(?!-)(?<id>[^"]+?)";\s+?LSHandlerURLScheme = (?:http|https);/.exec(T)?.groups.id??"com.apple.Safari";if(v==="com.apple.safari")return"com.apple.Safari";return v}import MT from"process";import{promisify as NT}from"util";import{execFile as UT,execFileSync as ES}from"child_process";var XT=NT(UT);async function A(T,{humanReadableOutput:S=!0,signal:v}={}){if(MT.platform!=="darwin")throw Error("macOS only");let $=S?[]:["-ss"],E={};if(v)E.signal=v;let{stdout:q}=await XT("osascript",["-e",T,$],E);return q.trim()}async function z(T){return A(`tell application "Finder" to set app_path to application file id "${T}" as string
3
3
  tell application "System Events" to get value of property list item "CFBundleName" of property list file (app_path & ":Contents:Info.plist")`)}import{promisify as jT}from"util";import{execFile as LT}from"child_process";var OT=jT(LT),N={MSEdgeHTM:{name:"Edge",id:"com.microsoft.edge"},MSEdgeBHTML:{name:"Edge Beta",id:"com.microsoft.edge.beta"},MSEdgeDHTML:{name:"Edge Dev",id:"com.microsoft.edge.dev"},AppXq0fevzme2pys62n3e0fbqa7peapykr8v:{name:"Edge",id:"com.microsoft.edge.old"},ChromeHTML:{name:"Chrome",id:"com.google.chrome"},ChromeBHTML:{name:"Chrome Beta",id:"com.google.chrome.beta"},ChromeDHTML:{name:"Chrome Dev",id:"com.google.chrome.dev"},ChromiumHTM:{name:"Chromium",id:"org.chromium.Chromium"},BraveHTML:{name:"Brave",id:"com.brave.Browser"},BraveBHTML:{name:"Brave Beta",id:"com.brave.Browser.beta"},BraveDHTML:{name:"Brave Dev",id:"com.brave.Browser.dev"},BraveSSHTM:{name:"Brave Nightly",id:"com.brave.Browser.nightly"},FirefoxURL:{name:"Firefox",id:"org.mozilla.firefox"},OperaStable:{name:"Opera",id:"com.operasoftware.Opera"},VivaldiHTM:{name:"Vivaldi",id:"com.vivaldi.Vivaldi"},"IE.HTTP":{name:"Internet Explorer",id:"com.microsoft.ie"}},KS=new Map(Object.entries(N));class P extends Error{}async function k(T=OT){let{stdout:S}=await T("reg",["QUERY"," HKEY_CURRENT_USER\\Software\\Microsoft\\Windows\\Shell\\Associations\\UrlAssociations\\http\\UserChoice","/v","ProgId"]),v=/ProgId\s*REG_SZ\s*(?<id>\S+)/.exec(S);if(!v)throw new P(`Cannot find Windows browser in stdout: ${JSON.stringify(S)}`);let{id:$}=v.groups,E=$.lastIndexOf("."),q=$.lastIndexOf("-"),J=E===-1?void 0:$.slice(0,E),R=q===-1?void 0:$.slice(0,q);return N[$]??N[J]??N[R]??{name:$,id:$}}var DT=_T(xT),zT=(T)=>T.toLowerCase().replaceAll(/(?:^|\s|-)\S/g,(S)=>S.toUpperCase());async function W(){if(F.platform==="darwin"){let T=await D();return{name:await z(T),id:T}}if(F.platform==="linux"){let{stdout:T}=await DT("xdg-mime",["query","default","x-scheme-handler/http"]),S=T.trim();return{name:zT(S.replace(/.desktop$/,"").replace("-"," ")),id:S}}if(F.platform==="win32")return k();throw Error("Only macOS, Linux, and Windows are supported")}var CT=FT(r.execFile),C=d.dirname(kT(import.meta.url)),w=d.join(C,"xdg-open"),{platform:H,arch:m}=I;async function fT(){let T=await x(),S=String.raw`(Get-ItemProperty -Path "HKCU:\Software\Microsoft\Windows\Shell\Associations\UrlAssociations\http\UserChoice").ProgId`,v=a.from(S,"utf16le").toString("base64"),{stdout:$}=await CT(T,["-NoProfile","-NonInteractive","-ExecutionPolicy","Bypass","-EncodedCommand",v],{encoding:"utf8"}),E=$.trim(),q={ChromeHTML:"com.google.chrome",BraveHTML:"com.brave.Browser",MSEdgeHTM:"com.microsoft.edge",FirefoxURL:"org.mozilla.firefox"};return q[E]?{id:q[E]}:{}}var h=async(T,S)=>{let v;for(let $ of T)try{return await S($)}catch(E){v=E}throw v},U=async(T)=>{if(T={wait:!1,background:!1,newInstance:!1,allowNonzeroExitCode:!1,...T},Array.isArray(T.app))return h(T.app,(R)=>U({...T,app:R}));let{name:S,arguments:v=[]}=T.app??{};if(v=[...v],Array.isArray(S))return h(S,(R)=>U({...T,app:{name:R,arguments:v}}));if(S==="browser"||S==="browserPrivate"){let R={"com.google.chrome":"chrome","google-chrome.desktop":"chrome","com.brave.Browser":"brave","org.mozilla.firefox":"firefox","firefox.desktop":"firefox","com.microsoft.msedge":"edge","com.microsoft.edge":"edge","com.microsoft.edgemac":"edge","microsoft-edge.desktop":"edge"},G={chrome:"--incognito",brave:"--incognito",firefox:"--private-window",edge:"--inPrivate"},K=Q?await fT():await W();if(K.id in R){let M=R[K.id];if(S==="browserPrivate")v.push(G[M]);return U({...T,app:{name:Z[M],arguments:v}})}throw Error(`${K.name} is not supported as a default browser`)}let $,E=[],q={};if(H==="darwin"){if($="open",T.wait)E.push("--wait-apps");if(T.background)E.push("--background");if(T.newInstance)E.push("--new");if(S)E.push("-a",S)}else if(H==="win32"||Q&&!Y()&&!S){if($=await x(),E.push("-NoProfile","-NonInteractive","-ExecutionPolicy","Bypass","-EncodedCommand"),!Q)q.windowsVerbatimArguments=!0;let R=["Start"];if(T.wait)R.push("-Wait");if(S){if(R.push(`"\`"${S}\`""`),T.target)v.push(T.target)}else if(T.target)R.push(`"${T.target}"`);if(v.length>0)v=v.map((G)=>`"\`"${G}\`""`),R.push("-ArgumentList",v.join(","));T.target=a.from(R.join(" "),"utf16le").toString("base64")}else{if(S)$=S;else{let R=!C||C==="/",G=!1;try{await WT.access(w,IT.X_OK),G=!0}catch{}$=I.versions.electron??(H==="android"||R||!G)?"xdg-open":w}if(v.length>0)E.push(...v);if(!T.wait)q.stdio="ignore",q.detached=!0}if(H==="darwin"&&v.length>0)E.push("--args",...v);if(T.target)E.push(T.target);let J=r.spawn($,E,q);if(T.wait)return new Promise((R,G)=>{J.once("error",G),J.once("close",(K)=>{if(!T.allowNonzeroExitCode&&K>0){G(Error(`Exited with code ${K}`));return}R(J)})});return J.unref(),J},lT=(T,S)=>{if(typeof T!=="string")throw TypeError("Expected a `target`");return U({...S,target:T})};function g(T){if(typeof T==="string"||Array.isArray(T))return T;let{[m]:S}=T;if(!S)throw Error(`${m} is not supported`);return S}function X({[H]:T},{wsl:S}){if(S&&Q)return g(S);if(!T)throw Error(`${H} is not supported`);return g(T)}var Z={};V(Z,"chrome",()=>X({darwin:"google chrome",win32:"chrome",linux:["google-chrome","google-chrome-stable","chromium"]},{wsl:{ia32:"/mnt/c/Program Files (x86)/Google/Chrome/Application/chrome.exe",x64:["/mnt/c/Program Files/Google/Chrome/Application/chrome.exe","/mnt/c/Program Files (x86)/Google/Chrome/Application/chrome.exe"]}}));V(Z,"brave",()=>X({darwin:"brave browser",win32:"brave",linux:["brave-browser","brave"]},{wsl:{ia32:"/mnt/c/Program Files (x86)/BraveSoftware/Brave-Browser/Application/brave.exe",x64:["/mnt/c/Program Files/BraveSoftware/Brave-Browser/Application/brave.exe","/mnt/c/Program Files (x86)/BraveSoftware/Brave-Browser/Application/brave.exe"]}}));V(Z,"firefox",()=>X({darwin:"firefox",win32:String.raw`C:\Program Files\Mozilla Firefox\firefox.exe`,linux:"firefox"},{wsl:"/mnt/c/Program Files/Mozilla Firefox/firefox.exe"}));V(Z,"edge",()=>X({darwin:"microsoft edge",win32:"msedge",linux:["microsoft-edge","microsoft-edge-dev"]},{wsl:"/mnt/c/Program Files (x86)/Microsoft/Edge/Application/msedge.exe"}));V(Z,"browser",()=>"browser");V(Z,"browserPrivate",()=>"browserPrivate");var e=lT;import{jsx as n}from"react/jsx-runtime";class s{from="";to=[];subject="No Subject";cc=[];bcc=[];attachments=[];template;headers={};static async send(T){let S=new this,v=f(p).defaultLocale,$=f(o),{to:E=S.to,from:q=S.from,subject:J=typeof S.subject==="string"?S.subject:S.subject[T.locale||v],cc:R=S.cc,bcc:G=S.bcc,attachments:K=S.attachments,data:M,headers:TT={}}=T,ST={...$.headers??{},...S.headers??{},...TT??{}};if(!(await $.filterRecipients(E)).length)return;let[l,vT]=await Promise.all([S.render({...M,locale:T.locale}),S.renderText({...M,locale:T.locale})]);if(process.env.EMAIL_DEBUG==="true"){let t=`${process.env.ROOT_DIR}/.debug/emails/${new Date().toISOString()}${J}.html`;if(await Bun.write(t,l),process.env.CI!=="true")await e(t);return}await $.send({bcc:G,cc:R,from:q,subject:J,to:E,attachments:K,html:l,headers:ST,text:vT,scheduledAt:T.scheduledAt})}static async preview(T){return await new this().render({...T.data,locale:T.locale})}async render(T){let S=this.template;return await i(n(S,{...T}))}async renderText(T){let S=this.template;return await i(n(S,{...T}),{plainText:!0})}}export{s as Email};
4
4
 
5
- //# debugId=1D5F2A1877DC667964756E2164756E21
5
+ //# debugId=72F3169ABE92AE5D64756E2164756E21
@@ -15,7 +15,7 @@
15
15
  "import {runAppleScript} from 'run-applescript';\n\nexport default async function bundleName(bundleId) {\n\treturn runAppleScript(`tell application \"Finder\" to set app_path to application file id \"${bundleId}\" as string\\ntell application \"System Events\" to get value of property list item \"CFBundleName\" of property list file (app_path & \":Contents:Info.plist\")`);\n}\n",
16
16
  "import {promisify} from 'node:util';\nimport {execFile} from 'node:child_process';\n\nconst execFileAsync = promisify(execFile);\n\n// TODO: Fix the casing of bundle identifiers in the next major version.\n\n// Windows doesn't have browser IDs in the same way macOS/Linux does so we give fake\n// ones that look real and match the macOS/Linux versions for cross-platform apps.\nconst windowsBrowserProgIds = {\n\tMSEdgeHTM: {name: 'Edge', id: 'com.microsoft.edge'}, // The missing `L` is correct.\n\tMSEdgeBHTML: {name: 'Edge Beta', id: 'com.microsoft.edge.beta'},\n\tMSEdgeDHTML: {name: 'Edge Dev', id: 'com.microsoft.edge.dev'},\n\tAppXq0fevzme2pys62n3e0fbqa7peapykr8v: {name: 'Edge', id: 'com.microsoft.edge.old'},\n\tChromeHTML: {name: 'Chrome', id: 'com.google.chrome'},\n\tChromeBHTML: {name: 'Chrome Beta', id: 'com.google.chrome.beta'},\n\tChromeDHTML: {name: 'Chrome Dev', id: 'com.google.chrome.dev'},\n\tChromiumHTM: {name: 'Chromium', id: 'org.chromium.Chromium'},\n\tBraveHTML: {name: 'Brave', id: 'com.brave.Browser'},\n\tBraveBHTML: {name: 'Brave Beta', id: 'com.brave.Browser.beta'},\n\tBraveDHTML: {name: 'Brave Dev', id: 'com.brave.Browser.dev'},\n\tBraveSSHTM: {name: 'Brave Nightly', id: 'com.brave.Browser.nightly'},\n\tFirefoxURL: {name: 'Firefox', id: 'org.mozilla.firefox'},\n\tOperaStable: {name: 'Opera', id: 'com.operasoftware.Opera'},\n\tVivaldiHTM: {name: 'Vivaldi', id: 'com.vivaldi.Vivaldi'},\n\t'IE.HTTP': {name: 'Internet Explorer', id: 'com.microsoft.ie'},\n};\n\nexport const _windowsBrowserProgIdMap = new Map(Object.entries(windowsBrowserProgIds));\n\nexport class UnknownBrowserError extends Error {}\n\nexport default async function defaultBrowser(_execFileAsync = execFileAsync) {\n\tconst {stdout} = await _execFileAsync('reg', [\n\t\t'QUERY',\n\t\t' HKEY_CURRENT_USER\\\\Software\\\\Microsoft\\\\Windows\\\\Shell\\\\Associations\\\\UrlAssociations\\\\http\\\\UserChoice',\n\t\t'/v',\n\t\t'ProgId',\n\t]);\n\n\tconst match = /ProgId\\s*REG_SZ\\s*(?<id>\\S+)/.exec(stdout);\n\tif (!match) {\n\t\tthrow new UnknownBrowserError(`Cannot find Windows browser in stdout: ${JSON.stringify(stdout)}`);\n\t}\n\n\tconst {id} = match.groups;\n\n\t// Windows can append a hash suffix to ProgIds using a dot or hyphen\n\t// (e.g., `ChromeHTML.ABC123`, `FirefoxURL-6F193CCC56814779`).\n\t// Try exact match first, then try without the suffix.\n\tconst dotIndex = id.lastIndexOf('.');\n\tconst hyphenIndex = id.lastIndexOf('-');\n\tconst baseIdByDot = dotIndex === -1 ? undefined : id.slice(0, dotIndex);\n\tconst baseIdByHyphen = hyphenIndex === -1 ? undefined : id.slice(0, hyphenIndex);\n\n\treturn windowsBrowserProgIds[id] ?? windowsBrowserProgIds[baseIdByDot] ?? windowsBrowserProgIds[baseIdByHyphen] ?? {name: id, id};\n}\n"
17
17
  ],
18
- "mappings": ";8OACA,YAAS,aCDT,kBACA,YAAQ,UACR,oBACA,wBAAQ,aACR,oBAAQ,cACR,6BACA,wBAAY,qBCNZ,uBACA,uBAAY,qBCDZ,uBACA,mBACA,kBCFA,mBCAA,kBAEA,IAAI,EAEJ,SAAS,EAAY,EAAG,CACvB,GAAI,CAEH,OADA,EAAG,SAAS,aAAa,EAClB,GACN,KAAM,CACP,MAAO,IAIT,SAAS,EAAe,EAAG,CAC1B,GAAI,CACH,OAAO,EAAG,aAAa,oBAAqB,MAAM,EAAE,SAAS,QAAQ,EACpE,KAAM,CACP,MAAO,IAIT,SAAwB,CAAQ,EAAG,CAElC,GAAI,IAAmB,OACtB,EAAiB,GAAa,GAAK,GAAgB,EAGpD,OAAO,EDxBR,IAAI,EAGE,GAAkB,IAAM,CAC7B,GAAI,CAEH,OADA,GAAG,SAAS,oBAAoB,EACzB,GACN,KAAM,CACP,MAAO,KAIT,SAAwB,CAAiB,EAAG,CAE3C,GAAI,IAAiB,OACpB,EAAe,GAAgB,GAAK,EAAS,EAG9C,OAAO,EDhBR,IAAM,EAAQ,IAAM,CACnB,GAAI,EAAQ,WAAa,QACxB,MAAO,GAGR,GAAI,GAAG,QAAQ,EAAE,YAAY,EAAE,SAAS,WAAW,EAAG,CACrD,GAAI,EAAkB,EACrB,MAAO,GAGR,MAAO,GAGR,GAAI,CACH,GAAI,EAAG,aAAa,gBAAiB,MAAM,EAAE,YAAY,EAAE,SAAS,WAAW,EAC9E,MAAO,CAAC,EAAkB,EAE1B,KAAM,EAGR,GACC,EAAG,WAAW,qCAAqC,GAChD,EAAG,WAAW,UAAU,EAE3B,M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,SAAW,CAAC,KACrB,IAAW,CAAC,CAClB,EAIA,GAAI,EAFe,MAAM,EAAK,iBAAiB,CAAE,GAEjC,OACd,OAGF,IAAO,EAAM,IAAQ,MAAM,QAAQ,IAAI,CACrC,EAAS,OAAO,IACV,EACJ,OAAQ,EAAK,MACf,CAAC,EACD,EAAS,WAAW,IACd,EACJ,OAAQ,EAAK,MACf,CAAC,CACH,CAAC,EAED,GAAI,QAAQ,IAAI,cAAgB,OAAQ,CACtC,IAAM,EAAW,GAAG,QAAQ,IAAI,0BAA0B,IAAI,KAAK,EAAE,YAAY,IAAI,SAErF,GADA,MAAM,IAAI,MAAM,EAAU,CAAI,EAC1B,QAAQ,IAAI,KAAO,OACrB,MAAM,EAAK,CAAQ,EAErB,OAGF,MAAM,EAAK,KAAK,CACd,MACA,KACA,OACA,UACA,KACA,cACA,OACA,QAAS,GACT,QACA,YAAa,EAAK,WACpB,CAAC,cAGU,QAAwB,CAEnC,EACA,CAIA,OAAO,MAFU,IAAI,KAAK,EAEJ,OAAO,IACxB,EAAK,KACR,OAAQ,EAAK,MACf,CAAC,OAGa,OAAqC,CAAC,EAAU,CAC9D,IAAM,EAAW,KAAK,SACtB,OAAO,MAAM,EAAO,EAAC,EAAD,IAAc,EAAO,CAAE,OAG7B,WAAyC,CAAC,EAAU,CAClE,IAAM,EAAW,KAAK,SACtB,OAAO,MAAM,EAAO,EAAC,EAAD,IAAc,EAAO,EAAI,CAAE,UAAW,EAAK,CAAC,EAEpE",
19
+ "debugId": "72F3169ABE92AE5D64756E2164756E21",
20
20
  "names": []
21
21
  }
@@ -1,4 +1,4 @@
1
1
  // @bun
2
- import{$b as j,Ab as c,Bb as d,Cb as e,Ib as f,Ub as g,Zb as h,_b as i,ac as k,cc as l,dc as m,ec as n,fc as o,yb as b}from"../chunk-c4r1zh9q.js";import"../chunk-3z4nwzvp.js";import"../chunk-eby61053.js";import{yd as a}from"../chunk-6x6gb7zg.js";import"../chunk-98sj7tkf.js";import"../chunk-nbx9mgmr.js";import"../chunk-8vnbvfmd.js";import"../chunk-asgfqcwd.js";import"../chunk-g0w87jtw.js";import"../chunk-w7fpm2pw.js";import"../chunk-j4rkk01q.js";import"../chunk-zwpx6z5f.js";export{i as Url,f as Storage,l as Redis,a as Redirect,m as RateLimiter,h as Query,j as Meta,g as Log,e as Lang,b as Facade,o as DB,k as Cookie,n as ConnectionQueries,c as Broadcast,d as Auth};
2
+ import{Hb as c,Ib as d,Ob as f,_b as g,dc as h,ec as i,fc as j,gc as k,ic as l,jc as m,kc as n,lc as o}from"../chunk-ear03axe.js";import"../chunk-7s1g3v1y.js";import"../chunk-tkv6cw94.js";import{id as b,jd as e}from"../chunk-y4djde42.js";import{Gd as a}from"../chunk-3d3nmr5g.js";import"../chunk-bq4w14a6.js";import"../chunk-cg53h5ht.js";import"../chunk-92793zh4.js";import"../chunk-3y9nf09k.js";import"../chunk-88pq4gmf.js";import"../chunk-mt2755rs.js";import"../chunk-qyaqg07q.js";import"../chunk-0h3jr9d9.js";export{i as Url,f as Storage,l as Redis,a as Redirect,m as RateLimiter,h as Query,j as Meta,g as Log,e as Lang,b as Facade,o as DB,k as Cookie,n as ConnectionQueries,c as Broadcast,d as Auth};
3
3
 
4
- //# debugId=B23818FEF0012F4764756E2164756E21
4
+ //# debugId=25F5EC18D86D946C64756E2164756E21
@@ -4,6 +4,6 @@
4
4
  "sourcesContent": [
5
5
  ],
6
6
  "mappings": "",
7
- "debugId": "B23818FEF0012F4764756E2164756E21",
7
+ "debugId": "25F5EC18D86D946C64756E2164756E21",
8
8
  "names": []
9
9
  }
@@ -1,4 +1,4 @@
1
1
  // @bun
2
- import{Ce as r,De as o}from"../chunk-g0w87jtw.js";import"../chunk-w7fpm2pw.js";import"../chunk-j4rkk01q.js";import"../chunk-zwpx6z5f.js";export{o as app,r as Application};
2
+ import{Le as r,Me as o}from"../chunk-mt2755rs.js";import"../chunk-qyaqg07q.js";import"../chunk-0h3jr9d9.js";export{o as app,r as Application};
3
3
 
4
- //# debugId=1953ABDA205F338D64756E2164756E21
4
+ //# debugId=FD3D2610C3B9403064756E2164756E21
@@ -4,6 +4,6 @@
4
4
  "sourcesContent": [
5
5
  ],
6
6
  "mappings": "",
7
- "debugId": "1953ABDA205F338D64756E2164756E21",
7
+ "debugId": "FD3D2610C3B9403064756E2164756E21",
8
8
  "names": []
9
9
  }
@@ -1 +1 @@
1
- {"version":3,"file":"ViewRouter.d.ts","sourceRoot":"","sources":["../../http/ViewRouter.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,iBAAiB,CAAC;AAEzD,OAAO,KAAK,EAAE,WAAW,EAAE,mBAAmB,EAAE,MAAM,wBAAwB,CAAC;AAE/E,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,cAAc,CAAC;AAC/C,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,eAAe,CAAC;AAEjD,KAAK,iBAAiB,CAAC,CAAC,SAAS,UAAU,UAAU,IAAI;KACtD,CAAC,IAAI,MAAM,YAAY,CAAC,CAAC,CAAC,GAAG,YAAY,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,SAAS,QAAQ,GAAG,CAAC,GAAG,KAAK;CAC9E,CAAC,MAAM,YAAY,CAAC,CAAC,CAAC,CAAC,CAAC;AAEzB,MAAM,MAAM,UAAU,GAAG,MAAM,CAC7B,MAAM,EACJ,SAAS,CAAC,GAAG,EAAE,GAAG,EAAE,GAAG,CAAC,GACxB,WAAW,CAAC,GAAG,EAAE,GAAG,EAAE,GAAG,EAAE,GAAG,CAAC,GAC/B,aAAa,CAAC,GAAG,EAAE,GAAG,EAAE,GAAG,CAAC,GAC5B,SAAS,CAAC,GAAG,EAAE,GAAG,CAAC,GACnB,CAAC,UAAU,UAAU,CAAC,CACzB,CAAC;AAEF,KAAK,eAAe,CAAC,KAAK,EAAE,MAAM,EAAE,MAAM,IAAI,CAC5C,GAAG,EAAE,WAAW,CAAC,KAAK,EAAE,MAAM,CAAC,KAC5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AW,GAAG,EAAE,EAC/B,CAAC,SAAS,MAAM,CAAC,GAAG,MAAM,CAAC,IACzB,CAAC,SAAS,GAAG,GACb,CAAC,CAAC,CAAC,CAAC,SAAS,UAAU,UAAU,GAC/B,oBAAoB,CAAC,CAAC,CAAC,CAAC,CAAC,EAAE,iBAAiB,CAAC,MAAM,EAAE,CAAC,CAAC,CAAC,GACxD,CAAC,CAAC,CAAC,CAAC,SAAS,WAAW,CAAC,GAAG,EAAE,GAAG,EAAE,GAAG,EAAE,GAAG,CAAC,GAC1C,iBAAiB,CAAC,CAAC,CAAC,CAAC,CAAC,EAAE,iBAAiB,CAAC,MAAM,EAAE,CAAC,CAAC,CAAC,GACrD,CAAC,CAAC,CAAC,CAAC,SAAS,SAAS,CAAC,GAAG,EAAE,GAAG,CAAC,GAC9B,KAAK,GACL,CAAC,CAAC,CAAC,CAAC,SAAS,SAAS,CAAC,GAAG,EAAE,GAAG,EAAE,GAAG,CAAC,GACnC,eAAe,CAAC,CAAC,CAAC,CAAC,CAAC,EAAE,iBAAiB,CAAC,MAAM,EAAE,CAAC,CAAC,CAAC,GACnD,KAAK,GACb,KAAK,CAAC;AAEV,MAAM,MAAM,aAAa,CACvB,CAAC,SAAS,UAAU,EACpB,MAAM,SAAS,WAAW,GAAG,EAAE,IAC7B,mBAAmB,CAAC,YAAY,CAAC,CAAC,CAAC,QAAQ,CAAC,EAAE,MAAM,CAAC,CAAC,CAAC"}
@@ -1,4 +1,4 @@
1
1
  // @bun
2
- import{Ad as u,Bd as v,Cd as w,Dd as x,Ed as y,Kd as z,Ld as A,Md as B,Od as C,Pd as D,Qd as E,Rd as F,Sd as G,Td as H,cd as a,dd as b,fd as c,gd as d,hd as e,id as f,jd as g,kd as h,md as i,nd as j,od as k,pd as l,qd as m,rd as n,sd as o,td as p,ud as q,vd as r,wd as s,zd as t}from"../chunk-6x6gb7zg.js";import"../chunk-98sj7tkf.js";import"../chunk-nbx9mgmr.js";import"../chunk-8vnbvfmd.js";import"../chunk-g0w87jtw.js";import"../chunk-w7fpm2pw.js";import"../chunk-j4rkk01q.js";import"../chunk-zwpx6z5f.js";export{e as toRangeHeaderValue,d as resolveRange,c as parseRangeHeader,f as parseContentRange,y as middlewareConfigDefaults,w as getCookies,h as formatUnsatisfiedContentRange,g as formatContentRange,x as defineMiddlewareConfig,l as createUnsatisfiableResponse,m as createStreamResponse,t as createFileResponse,E as clientIp,u as ViewRouter,j as ValidationError,b as ResourceController,i as RequestBreakerError,D as RateLimitMiddleware,C as RateLimitExceededError,p as RangeNotSatisfiableError,G as PoliciesServiceProvider,H as Policies,v as Middleware,o as InsufficientPermissionsError,k as HttpRequest,q as FileNotFoundError,B as CorsMiddleware,a as Controller,A as CacheMiddleware,F as CSRFMiddleware,n as AuthorizationError,z as AuthenticationMiddleware,r as AuthenticationError,s as ApiRouter};
2
+ import{$d as H,Ad as o,Bd as p,Cd as q,Dd as r,Ed as s,Hd as t,Id as u,Jd as v,Kd as w,Ld as x,Md as y,Sd as z,Td as A,Ud as B,Wd as C,Xd as D,Yd as E,Zd as F,_d as G,kd as a,ld as b,nd as c,od as d,pd as e,qd as f,rd as g,sd as h,ud as i,vd as j,wd as k,xd as l,yd as m,zd as n}from"../chunk-3d3nmr5g.js";import"../chunk-bq4w14a6.js";import"../chunk-cg53h5ht.js";import"../chunk-92793zh4.js";import"../chunk-3y9nf09k.js";import"../chunk-mt2755rs.js";import"../chunk-qyaqg07q.js";import"../chunk-0h3jr9d9.js";export{e as toRangeHeaderValue,d as resolveRange,c as parseRangeHeader,f as parseContentRange,y as middlewareConfigDefaults,w as getCookies,h as formatUnsatisfiedContentRange,g as formatContentRange,x as defineMiddlewareConfig,l as createUnsatisfiableResponse,m as createStreamResponse,t as createFileResponse,E as clientIp,u as ViewRouter,j as ValidationError,b as ResourceController,i as RequestBreakerError,D as RateLimitMiddleware,C as RateLimitExceededError,p as RangeNotSatisfiableError,G as PoliciesServiceProvider,H as Policies,v as Middleware,o as InsufficientPermissionsError,k as HttpRequest,q as FileNotFoundError,B as CorsMiddleware,a as Controller,A as CacheMiddleware,F as CSRFMiddleware,n as AuthorizationError,z as AuthenticationMiddleware,r as AuthenticationError,s as ApiRouter};
3
3
 
4
- //# debugId=840E86C6E68FE78464756E2164756E21
4
+ //# debugId=7519E40AFFF1950164756E2164756E21
@@ -4,6 +4,6 @@
4
4
  "sourcesContent": [
5
5
  ],
6
6
  "mappings": "",
7
- "debugId": "840E86C6E68FE78464756E2164756E21",
7
+ "debugId": "7519E40AFFF1950164756E2164756E21",
8
8
  "names": []
9
9
  }
@@ -1 +1 @@
1
- {"version":3,"file":"Dictionary.d.ts","sourceRoot":"","sources":["../../i18n/Dictionary.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EACV,sBAAsB,EACtB,4BAA4B,EAC5B,QAAQ,EACT,MAAM,eAAe,CAAC;AAEvB,KAAK,YAAY,GAAG,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC,CAAC;AAE3D,qBAAa,UAAU,CAAC,CAAC,SAAS,YAAY;IAEnC,IAAI,EAAE,MAAM;IACZ,UAAU,EAAE,CAAC;gBADb,IAAI,EAAE,MAAM,EACZ,UAAU,EAAE,CAAC;IAGtB,SAAS,CAAC,GAAG,EAAE,MAAM,CAAC;IAUtB,MAAM,CACJ,CAAC,SAAS,MAAM,CAAC,EACjB,CAAC,SAAS,MAAM,CAAC,CAAC,CAAC,CAAC,EACpB,CAAC,GAAG,QAAQ,CAAC,sBAAsB,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,EAE7C,GAAG,EAAE,CAAC,EACN,GAAG,IAAI,EAAE,CAAC,SAAS,MAAM,CAAC,MAAM,EAAE,KAAK,CAAC,GACpC,CAAC,IAAI,CAAC,EAAE;QAAE,MAAM,CAAC,EAAE,CAAC,GAAG,CAAC,MAAM,GAAG,EAAE,CAAC,CAAA;KAAE,CAAC,GACvC,CAAC,IAAI,EAAE;Q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AAC,CAAC,CAAC,CAAC;SACtD;KACF,GACJ,MAAM;CASV"}
@@ -1,4 +1,4 @@
1
1
  // @bun
2
- import{M as E}from"../chunk-8gb1w19q.js";import{rb as $,sb as D}from"../chunk-hnw1jy86.js";import"../chunk-k4mjcvsm.js";import{Cb as U}from"../chunk-c4r1zh9q.js";import"../chunk-3z4nwzvp.js";import"../chunk-eby61053.js";import"../chunk-6x6gb7zg.js";import"../chunk-98sj7tkf.js";import"../chunk-nbx9mgmr.js";import"../chunk-8vnbvfmd.js";import{Ae as K}from"../chunk-asgfqcwd.js";import"../chunk-g0w87jtw.js";import"../chunk-w7fpm2pw.js";import"../chunk-j4rkk01q.js";import"../chunk-zwpx6z5f.js";import{createElement as x,Fragment as C,isValidElement as R}from"react";function y(r,n){let s=Object.values(n).some((o)=>typeof o==="function"&&R(o(""))),g=/{{([^{}]+?)(?::([^{}\[\]]+?))?(?:\[(.*?)\])?}}/g;if(!s)return r.replace(g,(T,t,w,d)=>{let P=t.includes(":")?t.split(":")[0]:t,i=n[P];if(i===void 0)return T;if(typeof i==="function"){let e=i(d!==void 0?d:"");if(R(e))throw Error("JSX returned in string context");return String(e)}if(w)switch(w.toLowerCase()){case"number":return Number(i).toString();case"string":return String(i);case"boolean":return Boolean(i).toString();default:return String(i)}return String(i)});else{let o=[],T=0,t=null;while((t=g.exec(r))!==null){let[w,d,P,i]=t,c=t.index,e=d.includes(":")?d.split(":")[0]:d;if(c>T)o.push(r.substring(T,c));let f=n[e];if(f===void 0)o.push(w);else if(typeof f==="function"){let b=f(i!==void 0?i:"");o.push(b)}else if(P)switch(P.toLowerCase()){case"number":o.push(Number(f).toString());break;case"string":o.push(String(f));break;case"boolean":o.push(Boolean(f).toString());break;default:o.push(String(f))}else o.push(String(f));T=c+w.length}if(T<r.length)o.push(r.substring(T));return x(C,{},...o)}}class S{name;dictionary;constructor(r,n){this.name=r;this.dictionary=n}reference(r){if(typeof window<"u")throw Error("Cannot use reference in the browser");if(!this.dictionary?.[r])throw Error(`Translation not found for ${String(r)}`);return this.dictionary[r]}render(r,...n){let{locale:s=U.locale(),params:g}={params:{},...n[0]};if(typeof window<"u")throw Error("Cannot use render in the browser");if(!this.dictionary?.[r]?.[s])throw Error(`Translation not found for ${String(r)} in ${String(s)}`);return y(this.dictionary[r][s],g??{})}static create(r,n){return new S(r,n)}static text(r,...n){let{locale:s=U.locale(),params:g}={params:{},...n?.[0]};if(!r?.[s])throw Error(`Translation not found for ${String(s)}`);return y(r[s],g??{})}}export{D as translationConfigDefaults,$ as defineTranslationConfig,K as Translator,E as TranslationServiceProvider,S as Dictionary};
2
+ import{M as $}from"../chunk-2qn472j4.js";import{Ab as K,zb as C}from"../chunk-msz8rngs.js";import"../chunk-ttzkn1qd.js";import{jd as h}from"../chunk-y4djde42.js";import"../chunk-92793zh4.js";import"../chunk-3y9nf09k.js";import{Ie as S}from"../chunk-88pq4gmf.js";import"../chunk-mt2755rs.js";import"../chunk-qyaqg07q.js";import"../chunk-0h3jr9d9.js";import{createElement as R,Fragment as x,isValidElement as b}from"react";function P(r,n){let s=Object.values(n).some((i)=>typeof i==="function"&&b(i(""))),f=/{{([^{}]+?)(?::([^{}\[\]]+?))?(?:\[(.*?)\])?}}/g;if(!s)return r.replace(f,(e,d,T,a)=>{let g=d.includes(":")?d.split(":")[0]:d,o=n[g];if(o===void 0)return e;if(typeof o==="function"){let w=o(a!==void 0?a:"");if(b(w))throw Error("JSX returned in string context");return String(w)}if(T)switch(T.toLowerCase()){case"number":return Number(o).toString();case"string":return String(o);case"boolean":return Boolean(o).toString();default:return String(o)}return String(o)});else{let i=[],e=0,d=null;while((d=f.exec(r))!==null){let[T,a,g,o]=d,c=d.index,w=a.includes(":")?a.split(":")[0]:a;if(c>e)i.push(r.substring(e,c));let t=n[w];if(t===void 0)i.push(T);else if(typeof t==="function"){let U=t(o!==void 0?o:"");i.push(U)}else if(g)switch(g.toLowerCase()){case"number":i.push(Number(t).toString());break;case"string":i.push(String(t));break;case"boolean":i.push(Boolean(t).toString());break;default:i.push(String(t))}else i.push(String(t));e=c+T.length}if(e<r.length)i.push(r.substring(e));return R(x,{},...i)}}class y{name;dictionary;constructor(r,n){this.name=r;this.dictionary=n}reference(r){if(typeof window<"u")throw Error("Cannot use reference in the browser");if(!this.dictionary?.[r])throw Error(`Translation not found for ${String(r)}`);return this.dictionary[r]}render(r,...n){let{locale:s=h.locale(),params:f}={params:{},...n[0]};if(typeof window<"u")throw Error("Cannot use render in the browser");if(!this.dictionary?.[r]?.[s])throw Error(`Translation not found for ${String(r)} in ${String(s)}`);return P(this.dictionary[r][s],f??{})}static create(r,n){return new y(r,n)}static text(r,...n){let{locale:s=h.locale(),params:f}={params:{},...n?.[0]};if(!r?.[s])throw Error(`Translation not found for ${String(s)}`);return P(r[s],f??{})}}export{K as translationConfigDefaults,C as defineTranslationConfig,S as Translator,$ as TranslationServiceProvider,y as Dictionary};
3
3
 
4
- //# debugId=12E1D8677107AE9B64756E2164756E21
4
+ //# debugId=CF598147D467E95464756E2164756E21
@@ -3,9 +3,9 @@
3
3
  "sources": ["../utils/parseTranslation.tsx", "../i18n/Dictionary.ts"],
4
4
  "sourcesContent": [
5
5
  "import { createElement, Fragment, isValidElement, type JSX } from \"react\";\n\ntype TemplateParams = Record<\n string,\n string | ((p: unknown) => string | JSX.Element)\n>;\n\nexport function parseTranslation(template: string, params: TemplateParams) {\n // Check if we have any JSX in our parameters\n const hasJSX = Object.values(params).some(\n (value) =>\n typeof value === \"function\" &&\n isValidElement((value as (p: unknown) => unknown)(\"\")),\n );\n\n // Regular expression to match template variables:\n // {{name}} - simple variable\n // {{name:type}} - variable with type casting\n // {{name:[content]}} - variable with interpolated content\n const regex = /{{([^{}]+?)(?::([^{}\\[\\]]+?))?(?:\\[(.*?)\\])?}}/g;\n\n if (!hasJSX) {\n // Simple string replacement\n const result = template.replace(regex, (match, name, type, content) => {\n // Clean the name part by removing any colon if present\n const cleanName = name.includes(\":\") ? name.split(\":\")[0] : name;\n\n const value = params[cleanName];\n if (value === undefined) {\n return match; // Return original match if no parameter found\n }\n\n if (typeof value === \"function\") {\n // If value is a function, call it with the content if available\n const functionParam = content !== undefined ? content : \"\";\n const functionResult = value(functionParam);\n // Check if function returned JSX - this shouldn't happen in the string branch\n if (isValidElement(functionResult)) {\n throw new Error(\"JSX returned in string context\");\n }\n return String(functionResult);\n }\n\n // Handle type casting if specified\n if (type) {\n switch (type.toLowerCase()) {\n case \"number\":\n return Number(value).toString();\n case \"string\":\n return String(value);\n case \"boolean\":\n return Boolean(value).toString();\n default:\n return String(value);\n }\n }\n return String(value);\n });\n return result as any;\n } else {\n // JSX replacement - we'll split the template into parts\n const parts: Array<string | JSX.Element> = [];\n let lastIndex = 0;\n let match: RegExpExecArray | null = null;\n\n while ((match = regex.exec(template)) !== null) {\n const [fullMatch, name, type, content] = match;\n const matchIndex = match.index;\n\n // Clean the name part by removing any colon if present\n const cleanName = name.includes(\":\") ? name.split(\":\")[0] : name;\n\n // Add text before the match\n if (matchIndex > lastIndex) {\n parts.push(template.substring(lastIndex, matchIndex));\n }\n\n const value = params[cleanName];\n if (value === undefined) {\n // Keep original template variable if no parameter found\n parts.push(fullMatch);\n } else if (typeof value === \"function\") {\n // If value is a function, call it with the content if available\n const functionParam = content !== undefined ? content : \"\";\n const functionResult = value(functionParam);\n parts.push(functionResult);\n } else if (type) {\n // Handle type casting if specified\n switch (type.toLowerCase()) {\n case \"number\":\n parts.push(Number(value).toString());\n break;\n case \"string\":\n parts.push(String(value));\n break;\n case \"boolean\":\n parts.push(Boolean(value).toString());\n break;\n default:\n parts.push(String(value));\n }\n } else {\n parts.push(String(value));\n }\n\n lastIndex = matchIndex + fullMatch.length;\n }\n\n // Add any remaining text\n if (lastIndex < template.length) {\n parts.push(template.substring(lastIndex));\n }\n\n // Convert the parts array to JSX\n return createElement(Fragment, {}, ...parts) as any;\n }\n}\n",
6
- "import { Lang } from \"../facades\";\nimport { parseTranslation } from \"../utils/parseTranslation\";\nimport type {\n ParseTranslationParams,\n ParseTranslationParamsServer,\n Prettify,\n} from \"../utils/type\";\n\ntype Translations = Record<string, Record<string, string>>;\n\nexport class Dictionary<T extends Translations> {\n constructor(\n public name: string,\n public dictionary: T,\n ) {}\n\n reference(key: keyof T) {\n if (typeof window !== \"undefined\") {\n throw new Error(\"Cannot use reference in the browser\");\n }\n if (!this.dictionary?.[key]) {\n throw new Error(`Translation not found for ${String(key)}`);\n }\n return this.dictionary[key];\n }\n\n render<\n K extends keyof T,\n U extends keyof T[K],\n R = Prettify<ParseTranslationParams<T[K][U]>>,\n >(\n key: K,\n ...args: R extends Record<string, never>\n ? [args?: { locale?: U | (string & {}) }]\n : [args: { locale?: U | (string & {}); params: R }]\n ) {\n const { locale = Lang.locale(), params } = {\n params: {},\n ...args[0],\n };\n\n if (typeof window !== \"undefined\") {\n throw new Error(\"Cannot use render in the browser\");\n }\n\n if (!this.dictionary?.[key]?.[locale]) {\n throw new Error(\n `Translation not found for ${String(key)} in ${String(locale)}`,\n );\n }\n return parseTranslation(this.dictionary[key][locale], params ?? {});\n }\n\n static create<const T extends Translations>(name: string, translations: T) {\n return new Dictionary<T>(name, translations);\n }\n\n static text<const T extends Record<string, string>, U extends keyof T>(\n content: T,\n ...args: Prettify<ParseTranslationParamsServer<T[U]>> extends Record<\n string,\n never\n >\n ? [args?: { locale?: U | (string & {}) }]\n : [\n args: {\n locale?: U | (string & {});\n params: Prettify<ParseTranslationParamsServer<T[U]>>;\n },\n ]\n ): string {\n const { locale = Lang.locale(), params } = { params: {}, ...args?.[0] };\n\n if (!content?.[locale]) {\n throw new Error(`Translation not found for ${String(locale)}`);\n }\n\n return parseTranslation(content[locale], params ?? {});\n }\n}\n"
6
+ "// The module, not the `../facades` barrel. A dictionary is the one server-side\n// artifact a *component* test has to import — `<Page dictionaries={[…]}>` takes\n// the app's real `app/i18n/index.ts` — and the barrel drags the whole facade\n// set in behind it, including `Redis` and its `import { RedisClient } from\n// \"bun\"`. Under a browser-targeted runner (vitest/jsdom) that specifier does\n// not resolve, so importing the app's dictionaries failed to collect before it\n// rendered anything. `Lang` itself only needs the translator and the request\n// context.\nimport { Lang } from \"../facades/Lang\";\nimport { parseTranslation } from \"../utils/parseTranslation\";\nimport type {\n ParseTranslationParams,\n ParseTranslationParamsServer,\n Prettify,\n} from \"../utils/type\";\n\ntype Translations = Record<string, Record<string, string>>;\n\nexport class Dictionary<T extends Translations> {\n constructor(\n public name: string,\n public dictionary: T,\n ) {}\n\n reference(key: keyof T) {\n if (typeof window !== \"undefined\") {\n throw new Error(\"Cannot use reference in the browser\");\n }\n if (!this.dictionary?.[key]) {\n throw new Error(`Translation not found for ${String(key)}`);\n }\n return this.dictionary[key];\n }\n\n render<\n K extends keyof T,\n U extends keyof T[K],\n R = Prettify<ParseTranslationParams<T[K][U]>>,\n >(\n key: K,\n ...args: R extends Record<string, never>\n ? [args?: { locale?: U | (string & {}) }]\n : [args: { locale?: U | (string & {}); params: R }]\n ) {\n const { locale = Lang.locale(), params } = {\n params: {},\n ...args[0],\n };\n\n if (typeof window !== \"undefined\") {\n throw new Error(\"Cannot use render in the browser\");\n }\n\n if (!this.dictionary?.[key]?.[locale]) {\n throw new Error(\n `Translation not found for ${String(key)} in ${String(locale)}`,\n );\n }\n return parseTranslation(this.dictionary[key][locale], params ?? {});\n }\n\n static create<const T extends Translations>(name: string, translations: T) {\n return new Dictionary<T>(name, translations);\n }\n\n static text<const T extends Record<string, string>, U extends keyof T>(\n content: T,\n ...args: Prettify<ParseTranslationParamsServer<T[U]>> extends Record<\n string,\n never\n >\n ? [args?: { locale?: U | (string & {}) }]\n : [\n args: {\n locale?: U | (string & {});\n params: Prettify<ParseTranslationParamsServer<T[U]>>;\n },\n ]\n ): string {\n const { locale = Lang.locale(), params } = { params: {}, ...args?.[0] };\n\n if (!content?.[locale]) {\n throw new Error(`Translation not found for ${String(locale)}`);\n }\n\n return parseTranslation(content[locale], params ?? {});\n }\n}\n"
7
7
  ],
8
- "mappings": ";ojBAAA,mBAAS,SAAe,e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AAO,EAAG,EAEtE,GAAI,CAAC,IAAU,GACb,MAAU,MAAM,6BAA6B,OAAO,CAAM,GAAG,EAG/D,OAAO,EAAiB,EAAQ,GAAS,GAAU,CAAC,CAAC,EAEzD",
9
+ "debugId": "CF598147D467E95464756E2164756E21",
10
10
  "names": []
11
11
  }
@@ -2,6 +2,7 @@ import { Application } from "../foundation/Application";
2
2
  import type { ServiceProviderConstructor } from "../foundation/Application";
3
3
  import type { ServiceToken } from "../container/Container";
4
4
  import type { ConfigItems } from "../support/Repository";
5
+ import type { Service, ServiceConstructor } from "../support/Service";
5
6
  import { BroadcastManager } from "../services/pubsub/BroadcastManager";
6
7
  import { QueueManager } from "../services/queue/QueueManager";
7
8
  import { ApiRouteDispatcher } from "../services/router/ApiRouteDispatcher";
@@ -23,6 +24,21 @@ export declare class Kernel {
23
24
  * rebind anything the framework bound.
24
25
  */
25
26
  protected providers: ServiceProviderConstructor[];
27
+ /**
28
+ * The app's own singleton services. Each is constructed during the
29
+ * synchronous boot phase and its `boot()` awaited during the asynchronous
30
+ * one, in the order listed — so a service whose `boot()` depends on another
31
+ * goes after it.
32
+ *
33
+ * An entry is either the class itself or a configured instance from
34
+ * `Service.with({ ... })`. Listing is explicit rather than discovered because
35
+ * the order is load-bearing here, and because a service is always imported by
36
+ * whatever injects it — there is no file the import graph would miss.
37
+ */
38
+ protected services: Array<ServiceConstructor | Service>;
39
+ private serviceInstances;
40
+ private serviceTokens;
41
+ private servicesBooted;
26
42
  /**
27
43
  * The modules holding the app's model classes — normally
28
44
  * `[generated, models]`, the generated namespace and the barrel of subclasses
@@ -60,11 +76,24 @@ export declare class Kernel {
60
76
  * Phase two is `waitForBoot()`.
61
77
  */
62
78
  boot(): void;
79
+ /**
80
+ * Constructs every listed service and binds it into the container. Runs after
81
+ * the providers have registered, so a provider's `boot()` can `inject()` one;
82
+ * a `Service` constructor does no I/O, so doing this synchronously costs
83
+ * nothing beyond the field initializers.
84
+ */
85
+ private registerServices;
63
86
  /**
64
87
  * Phase two, asynchronous: every provider's `boot()` runs, in registration
65
88
  * order, after all of them have registered. Idempotent.
66
89
  */
67
90
  waitForBoot(): Promise<void>;
91
+ /**
92
+ * Phase two for services, after every provider's `boot()` — so a service may
93
+ * use the facades and anything else a provider owns. Idempotent, like the
94
+ * provider phase it follows.
95
+ */
96
+ private bootServices;
68
97
  run<T>(cb: () => T): T;
69
98
  /**
70
99
  * Resolve a service by token. Callers outside this module should prefer the
@@ -1 +1 @@
1
- {"version":3,"file":"Kernel.d.ts","sourceRoot":"","sources":["../../kernel/Kernel.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,WAAW,EAAE,MAAM,2BAA2B,CAAC;AACxD,OAAO,KAAK,EAAE,0BAA0B,EAAE,MAAM,2BAA2B,CAAC;AAC5E,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,wBAAwB,CAAC;AAC3D,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,uBAAuB,CAAC;AAIzD,OAAO,EAAE,gBAAgB,EAAE,MAAM,qCAAqC,CAAC;AACvE,OAAO,EAAE,YAAY,EAAE,MAAM,gCAAgC,CAAC;AAC9D,OAAO,EAAE,kBAAkB,EAAE,MAAM,uCAAuC,CAAC;AAC3E,OAAO,EAAE,mBAAmB,EAAE,MAAM,wCAAwC,CAAC;AAI7E;;;;GAIG;AACH,qBAAa,MAAM;IACjB;;;;OAIG;IACH,SAAS,CAAC,MAAM,EAAE,WAAW,CAAM;IAEnC;;;OAGG;IACH,SAAS,CAAC,SAAS,EAAE,0BAA0B,EAAE,CAAM;IAEvD;;;;;;;;;;;;;;;;;;;;;;;;;;;OA2BG;IACH,SAAS,CAAC,MAAM,EAAE,KAAK,CAAC,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC,CAAM;IAEtD,QAAQ,CAAC,GAAG,cAAqB;IAEjC;;;;;OAKG;IACH,IAAI;IAYJ;;;OAGG;IACG,WAAW;IAIjB,GAAG,CAAC,CAAC,EAAE,EAAE,EAAE,MA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