@stamhoofd/cli 2.122.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (348) hide show
  1. package/LICENSE.md +32 -0
  2. package/README.md +365 -0
  3. package/bin/stam.js +19 -0
  4. package/dist/base-command.d.ts +22 -0
  5. package/dist/base-command.d.ts.map +1 -0
  6. package/dist/base-command.js +23 -0
  7. package/dist/base-command.js.map +1 -0
  8. package/dist/command-flags.d.ts +8 -0
  9. package/dist/command-flags.d.ts.map +1 -0
  10. package/dist/command-flags.js +32 -0
  11. package/dist/command-flags.js.map +1 -0
  12. package/dist/commands/build.d.ts +12 -0
  13. package/dist/commands/build.d.ts.map +1 -0
  14. package/dist/commands/build.js +16 -0
  15. package/dist/commands/build.js.map +1 -0
  16. package/dist/commands/check/all.d.ts +12 -0
  17. package/dist/commands/check/all.d.ts.map +1 -0
  18. package/dist/commands/check/all.js +21 -0
  19. package/dist/commands/check/all.js.map +1 -0
  20. package/dist/commands/check/index.d.ts +8 -0
  21. package/dist/commands/check/index.d.ts.map +1 -0
  22. package/dist/commands/check/index.js +15 -0
  23. package/dist/commands/check/index.js.map +1 -0
  24. package/dist/commands/check/lint.d.ts +11 -0
  25. package/dist/commands/check/lint.d.ts.map +1 -0
  26. package/dist/commands/check/lint.js +16 -0
  27. package/dist/commands/check/lint.js.map +1 -0
  28. package/dist/commands/check/typecheck.d.ts +11 -0
  29. package/dist/commands/check/typecheck.d.ts.map +1 -0
  30. package/dist/commands/check/typecheck.js +16 -0
  31. package/dist/commands/check/typecheck.js.map +1 -0
  32. package/dist/commands/clean/index.d.ts +31 -0
  33. package/dist/commands/clean/index.d.ts.map +1 -0
  34. package/dist/commands/clean/index.js +131 -0
  35. package/dist/commands/clean/index.js.map +1 -0
  36. package/dist/commands/config/explain.d.ts +13 -0
  37. package/dist/commands/config/explain.d.ts.map +1 -0
  38. package/dist/commands/config/explain.js +26 -0
  39. package/dist/commands/config/explain.js.map +1 -0
  40. package/dist/commands/config/index.d.ts +8 -0
  41. package/dist/commands/config/index.d.ts.map +1 -0
  42. package/dist/commands/config/index.js +15 -0
  43. package/dist/commands/config/index.js.map +1 -0
  44. package/dist/commands/config/print.d.ts +13 -0
  45. package/dist/commands/config/print.d.ts.map +1 -0
  46. package/dist/commands/config/print.js +19 -0
  47. package/dist/commands/config/print.js.map +1 -0
  48. package/dist/commands/db/backup/index.d.ts +13 -0
  49. package/dist/commands/db/backup/index.d.ts.map +1 -0
  50. package/dist/commands/db/backup/index.js +31 -0
  51. package/dist/commands/db/backup/index.js.map +1 -0
  52. package/dist/commands/db/backup/list.d.ts +13 -0
  53. package/dist/commands/db/backup/list.d.ts.map +1 -0
  54. package/dist/commands/db/backup/list.js +38 -0
  55. package/dist/commands/db/backup/list.js.map +1 -0
  56. package/dist/commands/db/backup/remove.d.ts +15 -0
  57. package/dist/commands/db/backup/remove.d.ts.map +1 -0
  58. package/dist/commands/db/backup/remove.js +24 -0
  59. package/dist/commands/db/backup/remove.js.map +1 -0
  60. package/dist/commands/db/backup/rename.d.ts +15 -0
  61. package/dist/commands/db/backup/rename.d.ts.map +1 -0
  62. package/dist/commands/db/backup/rename.js +24 -0
  63. package/dist/commands/db/backup/rename.js.map +1 -0
  64. package/dist/commands/db/copy.d.ts +16 -0
  65. package/dist/commands/db/copy.d.ts.map +1 -0
  66. package/dist/commands/db/copy.js +27 -0
  67. package/dist/commands/db/copy.js.map +1 -0
  68. package/dist/commands/db/index.d.ts +8 -0
  69. package/dist/commands/db/index.d.ts.map +1 -0
  70. package/dist/commands/db/index.js +20 -0
  71. package/dist/commands/db/index.js.map +1 -0
  72. package/dist/commands/db/migrate.d.ts +13 -0
  73. package/dist/commands/db/migrate.d.ts.map +1 -0
  74. package/dist/commands/db/migrate.js +16 -0
  75. package/dist/commands/db/migrate.js.map +1 -0
  76. package/dist/commands/db/move.d.ts +16 -0
  77. package/dist/commands/db/move.d.ts.map +1 -0
  78. package/dist/commands/db/move.js +28 -0
  79. package/dist/commands/db/move.js.map +1 -0
  80. package/dist/commands/db/remove.d.ts +15 -0
  81. package/dist/commands/db/remove.d.ts.map +1 -0
  82. package/dist/commands/db/remove.js +25 -0
  83. package/dist/commands/db/remove.js.map +1 -0
  84. package/dist/commands/db/restore.d.ts +13 -0
  85. package/dist/commands/db/restore.d.ts.map +1 -0
  86. package/dist/commands/db/restore.js +31 -0
  87. package/dist/commands/db/restore.js.map +1 -0
  88. package/dist/commands/db/shell.d.ts +13 -0
  89. package/dist/commands/db/shell.d.ts.map +1 -0
  90. package/dist/commands/db/shell.js +20 -0
  91. package/dist/commands/db/shell.js.map +1 -0
  92. package/dist/commands/dev/index.d.ts +19 -0
  93. package/dist/commands/dev/index.d.ts.map +1 -0
  94. package/dist/commands/dev/index.js +63 -0
  95. package/dist/commands/dev/index.js.map +1 -0
  96. package/dist/commands/services/down.d.ts +11 -0
  97. package/dist/commands/services/down.d.ts.map +1 -0
  98. package/dist/commands/services/down.js +17 -0
  99. package/dist/commands/services/down.js.map +1 -0
  100. package/dist/commands/services/index.d.ts +8 -0
  101. package/dist/commands/services/index.d.ts.map +1 -0
  102. package/dist/commands/services/index.js +15 -0
  103. package/dist/commands/services/index.js.map +1 -0
  104. package/dist/commands/services/logs.d.ts +11 -0
  105. package/dist/commands/services/logs.d.ts.map +1 -0
  106. package/dist/commands/services/logs.js +15 -0
  107. package/dist/commands/services/logs.js.map +1 -0
  108. package/dist/commands/services/restart.d.ts +11 -0
  109. package/dist/commands/services/restart.d.ts.map +1 -0
  110. package/dist/commands/services/restart.js +18 -0
  111. package/dist/commands/services/restart.js.map +1 -0
  112. package/dist/commands/services/status.d.ts +11 -0
  113. package/dist/commands/services/status.d.ts.map +1 -0
  114. package/dist/commands/services/status.js +16 -0
  115. package/dist/commands/services/status.js.map +1 -0
  116. package/dist/commands/services/stop.d.ts +2 -0
  117. package/dist/commands/services/stop.d.ts.map +1 -0
  118. package/dist/commands/services/stop.js +2 -0
  119. package/dist/commands/services/stop.js.map +1 -0
  120. package/dist/commands/services/up.d.ts +11 -0
  121. package/dist/commands/services/up.d.ts.map +1 -0
  122. package/dist/commands/services/up.js +16 -0
  123. package/dist/commands/services/up.js.map +1 -0
  124. package/dist/commands/setup/index.d.ts +22 -0
  125. package/dist/commands/setup/index.d.ts.map +1 -0
  126. package/dist/commands/setup/index.js +69 -0
  127. package/dist/commands/setup/index.js.map +1 -0
  128. package/dist/commands/sso/config.d.ts +16 -0
  129. package/dist/commands/sso/config.d.ts.map +1 -0
  130. package/dist/commands/sso/config.js +21 -0
  131. package/dist/commands/sso/config.js.map +1 -0
  132. package/dist/commands/sso/index.d.ts +8 -0
  133. package/dist/commands/sso/index.d.ts.map +1 -0
  134. package/dist/commands/sso/index.js +16 -0
  135. package/dist/commands/sso/index.js.map +1 -0
  136. package/dist/commands/sso/logs.d.ts +13 -0
  137. package/dist/commands/sso/logs.d.ts.map +1 -0
  138. package/dist/commands/sso/logs.js +17 -0
  139. package/dist/commands/sso/logs.js.map +1 -0
  140. package/dist/commands/sso/start.d.ts +17 -0
  141. package/dist/commands/sso/start.d.ts.map +1 -0
  142. package/dist/commands/sso/start.js +32 -0
  143. package/dist/commands/sso/start.js.map +1 -0
  144. package/dist/commands/sso/stop.d.ts +13 -0
  145. package/dist/commands/sso/stop.d.ts.map +1 -0
  146. package/dist/commands/sso/stop.js +18 -0
  147. package/dist/commands/sso/stop.js.map +1 -0
  148. package/dist/commands/status.d.ts +15 -0
  149. package/dist/commands/status.d.ts.map +1 -0
  150. package/dist/commands/status.js +61 -0
  151. package/dist/commands/status.js.map +1 -0
  152. package/dist/commands/test/all.d.ts +12 -0
  153. package/dist/commands/test/all.d.ts.map +1 -0
  154. package/dist/commands/test/all.js +19 -0
  155. package/dist/commands/test/all.js.map +1 -0
  156. package/dist/commands/test/e2e.d.ts +16 -0
  157. package/dist/commands/test/e2e.d.ts.map +1 -0
  158. package/dist/commands/test/e2e.js +32 -0
  159. package/dist/commands/test/e2e.js.map +1 -0
  160. package/dist/commands/test/index.d.ts +8 -0
  161. package/dist/commands/test/index.d.ts.map +1 -0
  162. package/dist/commands/test/index.js +16 -0
  163. package/dist/commands/test/index.js.map +1 -0
  164. package/dist/commands/test/unit.d.ts +12 -0
  165. package/dist/commands/test/unit.d.ts.map +1 -0
  166. package/dist/commands/test/unit.js +17 -0
  167. package/dist/commands/test/unit.js.map +1 -0
  168. package/dist/config/build-config.d.ts +15 -0
  169. package/dist/config/build-config.d.ts.map +1 -0
  170. package/dist/config/build-config.js +8 -0
  171. package/dist/config/build-config.js.map +1 -0
  172. package/dist/config/caddy-config.d.ts +122 -0
  173. package/dist/config/caddy-config.d.ts.map +1 -0
  174. package/dist/config/caddy-config.js +127 -0
  175. package/dist/config/caddy-config.js.map +1 -0
  176. package/dist/config/development-config.d.ts +48 -0
  177. package/dist/config/development-config.d.ts.map +1 -0
  178. package/dist/config/development-config.js +230 -0
  179. package/dist/config/development-config.js.map +1 -0
  180. package/dist/config/internal-secrets.d.ts +13 -0
  181. package/dist/config/internal-secrets.d.ts.map +1 -0
  182. package/dist/config/internal-secrets.js +65 -0
  183. package/dist/config/internal-secrets.js.map +1 -0
  184. package/dist/config/shared-service-config.d.ts +60 -0
  185. package/dist/config/shared-service-config.d.ts.map +1 -0
  186. package/dist/config/shared-service-config.js +94 -0
  187. package/dist/config/shared-service-config.js.map +1 -0
  188. package/dist/config/shared-service-profile.d.ts +29 -0
  189. package/dist/config/shared-service-profile.d.ts.map +1 -0
  190. package/dist/config/shared-service-profile.js +56 -0
  191. package/dist/config/shared-service-profile.js.map +1 -0
  192. package/dist/context/create-context.d.ts +19 -0
  193. package/dist/context/create-context.d.ts.map +1 -0
  194. package/dist/context/create-context.js +26 -0
  195. package/dist/context/create-context.js.map +1 -0
  196. package/dist/context/instance.d.ts +12 -0
  197. package/dist/context/instance.d.ts.map +1 -0
  198. package/dist/context/instance.js +26 -0
  199. package/dist/context/instance.js.map +1 -0
  200. package/dist/context/port-allocation.d.ts +3 -0
  201. package/dist/context/port-allocation.d.ts.map +1 -0
  202. package/dist/context/port-allocation.js +77 -0
  203. package/dist/context/port-allocation.js.map +1 -0
  204. package/dist/context/ports.d.ts +14 -0
  205. package/dist/context/ports.d.ts.map +1 -0
  206. package/dist/context/ports.js +17 -0
  207. package/dist/context/ports.js.map +1 -0
  208. package/dist/context/project-path.d.ts +2 -0
  209. package/dist/context/project-path.d.ts.map +1 -0
  210. package/dist/context/project-path.js +7 -0
  211. package/dist/context/project-path.js.map +1 -0
  212. package/dist/context/workspace.d.ts +5 -0
  213. package/dist/context/workspace.d.ts.map +1 -0
  214. package/dist/context/workspace.js +47 -0
  215. package/dist/context/workspace.js.map +1 -0
  216. package/dist/help.d.ts +13 -0
  217. package/dist/help.d.ts.map +1 -0
  218. package/dist/help.js +125 -0
  219. package/dist/help.js.map +1 -0
  220. package/dist/index.d.ts +13 -0
  221. package/dist/index.d.ts.map +1 -0
  222. package/dist/index.js +10 -0
  223. package/dist/index.js.map +1 -0
  224. package/dist/runtime/command-runner.d.ts +20 -0
  225. package/dist/runtime/command-runner.d.ts.map +1 -0
  226. package/dist/runtime/command-runner.js +75 -0
  227. package/dist/runtime/command-runner.js.map +1 -0
  228. package/dist/runtime/database-command-helpers.d.ts +16 -0
  229. package/dist/runtime/database-command-helpers.d.ts.map +1 -0
  230. package/dist/runtime/database-command-helpers.js +64 -0
  231. package/dist/runtime/database-command-helpers.js.map +1 -0
  232. package/dist/runtime/db-backup-helpers.d.ts +24 -0
  233. package/dist/runtime/db-backup-helpers.d.ts.map +1 -0
  234. package/dist/runtime/db-backup-helpers.js +145 -0
  235. package/dist/runtime/db-backup-helpers.js.map +1 -0
  236. package/dist/runtime/live-output.d.ts +31 -0
  237. package/dist/runtime/live-output.d.ts.map +1 -0
  238. package/dist/runtime/live-output.js +139 -0
  239. package/dist/runtime/live-output.js.map +1 -0
  240. package/dist/runtime/manifest-store.d.ts +66 -0
  241. package/dist/runtime/manifest-store.d.ts.map +1 -0
  242. package/dist/runtime/manifest-store.js +188 -0
  243. package/dist/runtime/manifest-store.js.map +1 -0
  244. package/dist/runtime/monorepo-runner.d.ts +20 -0
  245. package/dist/runtime/monorepo-runner.d.ts.map +1 -0
  246. package/dist/runtime/monorepo-runner.js +175 -0
  247. package/dist/runtime/monorepo-runner.js.map +1 -0
  248. package/dist/runtime/one-password.d.ts +7 -0
  249. package/dist/runtime/one-password.d.ts.map +1 -0
  250. package/dist/runtime/one-password.js +90 -0
  251. package/dist/runtime/one-password.js.map +1 -0
  252. package/dist/runtime/output-target.d.ts +13 -0
  253. package/dist/runtime/output-target.d.ts.map +1 -0
  254. package/dist/runtime/output-target.js +22 -0
  255. package/dist/runtime/output-target.js.map +1 -0
  256. package/dist/runtime/show-help.d.ts +3 -0
  257. package/dist/runtime/show-help.d.ts.map +1 -0
  258. package/dist/runtime/show-help.js +6 -0
  259. package/dist/runtime/show-help.js.map +1 -0
  260. package/dist/runtime/status.d.ts +10 -0
  261. package/dist/runtime/status.d.ts.map +1 -0
  262. package/dist/runtime/status.js +28 -0
  263. package/dist/runtime/status.js.map +1 -0
  264. package/dist/runtime/ux.d.ts +62 -0
  265. package/dist/runtime/ux.d.ts.map +1 -0
  266. package/dist/runtime/ux.js +255 -0
  267. package/dist/runtime/ux.js.map +1 -0
  268. package/dist/services/definitions/caddy-service.d.ts +31 -0
  269. package/dist/services/definitions/caddy-service.d.ts.map +1 -0
  270. package/dist/services/definitions/caddy-service.js +93 -0
  271. package/dist/services/definitions/caddy-service.js.map +1 -0
  272. package/dist/services/definitions/coredns-service.d.ts +20 -0
  273. package/dist/services/definitions/coredns-service.d.ts.map +1 -0
  274. package/dist/services/definitions/coredns-service.js +43 -0
  275. package/dist/services/definitions/coredns-service.js.map +1 -0
  276. package/dist/services/definitions/maildev-service.d.ts +14 -0
  277. package/dist/services/definitions/maildev-service.d.ts.map +1 -0
  278. package/dist/services/definitions/maildev-service.js +28 -0
  279. package/dist/services/definitions/maildev-service.js.map +1 -0
  280. package/dist/services/definitions/mysql-service.d.ts +19 -0
  281. package/dist/services/definitions/mysql-service.d.ts.map +1 -0
  282. package/dist/services/definitions/mysql-service.js +41 -0
  283. package/dist/services/definitions/mysql-service.js.map +1 -0
  284. package/dist/services/definitions/rustfs-service.d.ts +16 -0
  285. package/dist/services/definitions/rustfs-service.d.ts.map +1 -0
  286. package/dist/services/definitions/rustfs-service.js +36 -0
  287. package/dist/services/definitions/rustfs-service.js.map +1 -0
  288. package/dist/services/definitions/sso-service.d.ts +27 -0
  289. package/dist/services/definitions/sso-service.d.ts.map +1 -0
  290. package/dist/services/definitions/sso-service.js +41 -0
  291. package/dist/services/definitions/sso-service.js.map +1 -0
  292. package/dist/services/definitions/stripe-service.d.ts +26 -0
  293. package/dist/services/definitions/stripe-service.d.ts.map +1 -0
  294. package/dist/services/definitions/stripe-service.js +70 -0
  295. package/dist/services/definitions/stripe-service.js.map +1 -0
  296. package/dist/services/docker-service.d.ts +39 -0
  297. package/dist/services/docker-service.d.ts.map +1 -0
  298. package/dist/services/docker-service.js +98 -0
  299. package/dist/services/docker-service.js.map +1 -0
  300. package/dist/services/docker.d.ts +23 -0
  301. package/dist/services/docker.d.ts.map +1 -0
  302. package/dist/services/docker.js +86 -0
  303. package/dist/services/docker.js.map +1 -0
  304. package/dist/services/manager.d.ts +25 -0
  305. package/dist/services/manager.d.ts.map +1 -0
  306. package/dist/services/manager.js +238 -0
  307. package/dist/services/manager.js.map +1 -0
  308. package/dist/services/registry.d.ts +3 -0
  309. package/dist/services/registry.d.ts.map +1 -0
  310. package/dist/services/registry.js +13 -0
  311. package/dist/services/registry.js.map +1 -0
  312. package/dist/services/service.d.ts +24 -0
  313. package/dist/services/service.d.ts.map +1 -0
  314. package/dist/services/service.js +2 -0
  315. package/dist/services/service.js.map +1 -0
  316. package/dist/services/shared-services.d.ts +17 -0
  317. package/dist/services/shared-services.d.ts.map +1 -0
  318. package/dist/services/shared-services.js +67 -0
  319. package/dist/services/shared-services.js.map +1 -0
  320. package/dist/services/sso-config.d.ts +14 -0
  321. package/dist/services/sso-config.d.ts.map +1 -0
  322. package/dist/services/sso-config.js +106 -0
  323. package/dist/services/sso-config.js.map +1 -0
  324. package/dist/services/stripe.d.ts +4 -0
  325. package/dist/services/stripe.d.ts.map +1 -0
  326. package/dist/services/stripe.js +8 -0
  327. package/dist/services/stripe.js.map +1 -0
  328. package/dist/workflows/setup-machine.d.ts +55 -0
  329. package/dist/workflows/setup-machine.d.ts.map +1 -0
  330. package/dist/workflows/setup-machine.js +529 -0
  331. package/dist/workflows/setup-machine.js.map +1 -0
  332. package/dist/workflows/setup-node.d.ts +14 -0
  333. package/dist/workflows/setup-node.d.ts.map +1 -0
  334. package/dist/workflows/setup-node.js +49 -0
  335. package/dist/workflows/setup-node.js.map +1 -0
  336. package/dist/workflows/setup-shell.d.ts +32 -0
  337. package/dist/workflows/setup-shell.d.ts.map +1 -0
  338. package/dist/workflows/setup-shell.js +104 -0
  339. package/dist/workflows/setup-shell.js.map +1 -0
  340. package/dist/workflows/start-dev.d.ts +13 -0
  341. package/dist/workflows/start-dev.d.ts.map +1 -0
  342. package/dist/workflows/start-dev.js +339 -0
  343. package/dist/workflows/start-dev.js.map +1 -0
  344. package/dist/workflows/start-services.d.ts +3 -0
  345. package/dist/workflows/start-services.d.ts.map +1 -0
  346. package/dist/workflows/start-services.js +6 -0
  347. package/dist/workflows/start-services.js.map +1 -0
  348. package/package.json +69 -0
package/LICENSE.md ADDED
@@ -0,0 +1,32 @@
1
+ Free Use License for Non-Profit Organizations
2
+
3
+ Copyright 2020 Codawood BV
4
+
5
+ Permission is hereby granted, free of charge, to any non-profit organization with fewer than 2,000 members (each, a “Licensee”), to use this software and associated documentation files (the “Software”), subject to the following conditions:
6
+
7
+ 1. Eligibility:
8
+ This license applies only if neither the Licensee nor, if applicable, its parent or umbrella organization, is already subject to an existing license for this project. For the purposes of this license, a “parent or umbrella organization” means any organization with which the Licensee is affiliated, coordinated, or represented as part of a larger collective, including but not limited to national associations or federations.
9
+
10
+ 2. Modifications:
11
+ Modifications to the Software are permitted only if they are published publicly under the MIT License, covering only the modifications; the original Software remains under this license and may not be sublicensed without a separate agreement. Any modification made by a Licensee (other than modifications by the original author, its representatives, or the copyright owner) shall be deemed to be distributed under the MIT License. Submission of modifications through publicly accessible channels, including but not limited to pull requests on code repositories such as GitHub, shall be considered an explicit acknowledgment and grant by the Licensee that such modifications are made available under the MIT License. Licensees may not sublicense, transfer, or assign the rights granted under this license except as expressly permitted herein.
12
+
13
+ 3. Precedence of Existing Licenses:
14
+ If the Licensee, or its parent or umbrella organization, is already subject to an existing license for this project, that license shall take precedence, and no additional free license is granted. Nothing in this license shall be construed to override any pre-existing exclusive license agreement.
15
+
16
+ 4. Data Protection / GDPR Responsibility:
17
+ Licensees are solely responsible for ensuring that any processing of personal data using this software complies with applicable data protection laws, including the EU General Data Protection Regulation (GDPR).
18
+
19
+ 5. Termination and Revocation:
20
+ The copyright holders may revoke this license at any time, at their sole discretion.
21
+
22
+ 6. Governing Law:
23
+ This license shall be governed by and construed in accordance with the laws of Belgium, without regard to conflict of law principles.
24
+
25
+ 7. Third-Party Licenses:
26
+ Certain files or components included in the Software may be governed by separate licenses, including open-source licenses, or contributed by third parties under different terms. Such files are not automatically covered by this license. Licensees are responsible for reviewing and complying with any additional license terms that apply to these files.
27
+
28
+ For the purposes of this license, a “non-profit organization” means an entity recognized as non-profit under applicable law in its jurisdiction, which does not distribute profits to its members or owners.
29
+
30
+ THE SOFTWARE IS PROVIDED “AS IS”, WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
31
+
32
+ The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
package/README.md ADDED
@@ -0,0 +1,365 @@
1
+ # Stamhoofd CLI
2
+
3
+ `stam` is the development CLI for this repository. It manages local setup, shared services, app processes, development configuration, database helpers, SSO helpers, tests, and cleanup.
4
+
5
+ ## Quick Start
6
+
7
+ ```bash
8
+ yarn install
9
+ yarn stam setup
10
+ yarn stam dev all
11
+ ```
12
+
13
+ Run `yarn stam setup shell` to install the CLI alias `stam` in your .zshrc or .bashrc (that removes the need to type `yarn` and the need to always run commands in the project root).
14
+
15
+ Open the dashboard URL printed by the CLI, or run `yarn stam status` to see active services, instances, URLs, and credentials.
16
+
17
+ Run `yarn stam --help` or `yarn stam <topic> --help` for command help.
18
+
19
+ ## For CLI Users
20
+
21
+ ### Commands
22
+
23
+ | Area | Command | Purpose |
24
+ | ----------- | ------------------------------------ | ------------------------------------------------------------------------ |
25
+ | Build | `yarn stam build` | Build shared packages and all app packages for the selected environment. |
26
+ | Setup | `yarn stam setup` | Check the machine and offer recommended setup fixes. |
27
+ | Setup | `yarn stam setup node` | Install the Node.js version from `.nvmrc` using fnm or nvm. |
28
+ | Setup | `yarn stam setup dns` | Configure local `.stamhoofd` DNS. |
29
+ | Setup | `yarn stam setup cert` | Trust the local Caddy HTTPS authority. |
30
+ | Development | `yarn stam dev all` | Start shared services and the full app stack. |
31
+ | Development | `yarn stam dev backend` | Start backend apps for the current instance. |
32
+ | Development | `yarn stam dev frontend` | Start frontend apps only. |
33
+ | Development | `yarn stam dev instance` | Start this workspace instance using shared services. |
34
+ | Services | `yarn stam services up` | Start shared Docker services. |
35
+ | Services | `yarn stam services status` | Show shared service status. |
36
+ | Services | `yarn stam services logs` | Tail shared service logs. |
37
+ | Services | `yarn stam services restart` | Restart shared services with interactive progress output. |
38
+ | Services | `yarn stam services down` | Stop shared services. |
39
+ | Services | `yarn stam services stop` | Alias for `yarn stam services down`. |
40
+ | Status | `yarn stam status` | Show shared services, active instances, URLs, and credentials. |
41
+ | Config | `yarn stam config explain` | Explain resolved instance config. |
42
+ | Config | `yarn stam config print` | Print resolved domains and backend environment values as JSON. |
43
+ | Database | `yarn stam db shell` | Open a MySQL shell for the current local database. |
44
+ | Database | `yarn stam db migrate` | Build shared packages and run migrations. |
45
+ | SSO | `yarn stam sso config` | Print local SSO client, user, and issuer settings. |
46
+ | SSO | `yarn stam sso start <redirect-uri>` | Start Keycloak and import the local realm. |
47
+ | SSO | `yarn stam sso logs` | Tail Keycloak logs. |
48
+ | SSO | `yarn stam sso stop` | Stop the local Keycloak container. |
49
+ | Tests | `yarn stam test unit` | Run unit tests with isolated MySQL. |
50
+ | Tests | `yarn stam test e2e` | Run Playwright tests. |
51
+ | Tests | `yarn stam test all --ci` | Run unit and E2E tests in CI mode. |
52
+ | Checks | `yarn stam check lint` | Run ESLint across the monorepo. |
53
+ | Checks | `yarn stam check typecheck` | Run TypeScript checks across the monorepo. |
54
+ | Checks | `yarn stam check all` | Run build, lint, typecheck, unit tests, and E2E tests. |
55
+ | Cleanup | `yarn stam clean build` | Remove build artifacts. |
56
+ | Cleanup | `yarn stam clean db` | Drop the selected local MySQL database after confirmation. |
57
+ | Cleanup | `yarn stam clean sso` | Stop the local SSO server. |
58
+ | Cleanup | `yarn stam clean services` | Stop shared services. |
59
+ | Cleanup | `yarn stam clean all` | Clean build artifacts and stop shared services. |
60
+
61
+ ### Development Configuration
62
+
63
+ `shared/cli` owns local development configuration. Backend and frontend development builds load domains, ports, database settings, storage settings, and app environment values from `@stamhoofd/cli`.
64
+
65
+ The main config contract lives in `src/config/development-config.ts`. Keep local-development settings there first, then consume the resolved config from commands, workflows, Caddy, SSO, Stripe, status output, or app bootstrapping.
66
+
67
+ Inspect the current config with:
68
+
69
+ ```bash
70
+ yarn stam config explain
71
+ yarn stam config print
72
+ yarn stam config print --env keeo
73
+ ```
74
+
75
+ ### Instances And Ports
76
+
77
+ The CLI infers an instance from the workspace, selected environment, and optional overrides.
78
+
79
+ Useful flags:
80
+
81
+ - `--env <name>` selects the development environment. The default is `stamhoofd`.
82
+ - `--name <name>` overrides the inferred instance name.
83
+ - `--verbose` prints extra diagnostics and commands.
84
+
85
+ Useful environment variables:
86
+
87
+ - `STAMHOOFD_WORKSPACE_NAME` overrides the workspace name.
88
+ - `STAMHOOFD_PRIMARY_INSTANCE=1` forces primary-instance behavior.
89
+ - `STAMHOOFD_INSTANCE_PREFIX` overrides the domain prefix.
90
+ - `STAMHOOFD_PORT_OFFSET` overrides the deterministic port offset.
91
+ - `STAMHOOFD_DOMAIN` overrides the shared local domain, defaulting to `stamhoofd`.
92
+ - `MYSQL_PORT` overrides the local MySQL host port, defaulting to `3307`.
93
+ - `STAMHOOFD_MYSQL_INNODB_BUFFER_POOL_SIZE` tunes the MySQL container InnoDB buffer pool size (e.g. `512M`, `1G`), defaulting to `4G`.
94
+ - `STAMHOOFD_MYSQL_INNODB_BUFFER_POOL_INSTANCES` tunes the MySQL container InnoDB buffer pool instances defaulting to `4`.
95
+ - `STAMHOOFD_MYSQL_SORT_BUFFER_SIZE` tunes the MySQL container sort buffer size (e.g. `8M`), defaulting to `2M`.
96
+ - `PUBLIC_IP`: Publish DNS records to your computers public IP address, and make Caddy listen on 0.0.0.0 instead of localhost. Useful for testing on local devices. E.g. `PUBLIC_IP=192.168.1.7 stam services restart` `PUBLIC_IP=192.168.1.7 stam dev all`
97
+
98
+ The primary `stamhoofd` instance uses base ports. With Git, the primary instance is the first worktree in `git worktree list --porcelain`. With jj, it is the first workspace in `jj workspace list`. Other worktrees and workspaces get deterministic offsets based on the workspace name so multiple workspaces can run on the same machine without changing databases when branches change.
99
+
100
+ When needing a heavy duty MySQL instance to test migrations, you can restart MySQL using:
101
+
102
+ ```
103
+ STAMHOOFD_MYSQL_INNODB_BUFFER_POOL_INSTANCES=10 \
104
+ STAMHOOFD_MYSQL_SORT_BUFFER_SIZE=64M \
105
+ STAMHOOFD_MYSQL_INNODB_BUFFER_POOL_SIZE=16G \
106
+ stam services restart
107
+ ```
108
+
109
+ ### Shared Services
110
+
111
+ Shared services run as Docker containers:
112
+
113
+ - MySQL: `stamhoofd-mysql`
114
+ - MailDev: `stamhoofd-maildev`
115
+ - RustFS: `stamhoofd-rustfs`
116
+ - CoreDNS: `stamhoofd-coredns`
117
+ - Caddy: `stamhoofd-caddy`
118
+
119
+ The setup is intentionally different where Docker behaves differently:
120
+
121
+ - Linux runs Caddy on unprivileged ports `8080/8443` and uses `sudo iptables` redirects from `80/443`.
122
+ - Linux configures split DNS through `systemd-resolved`, pointing `.stamhoofd` to CoreDNS on `127.0.0.1:1053`.
123
+ - macOS uses Docker Desktop bridge networking for Caddy, publishes `80/443` directly, and proxies back to host app ports through `host.docker.internal`.
124
+ - macOS configures `/etc/resolver/stamhoofd` with `nameserver 127.0.0.1`, so only the `stamhoofd` resolver domain and its subdomains use local CoreDNS on port `53`.
125
+ - MySQL listens on host port `3307` by default and still uses container port `3306`.
126
+
127
+ Start and inspect them with:
128
+
129
+ ```bash
130
+ yarn stam services up
131
+ yarn stam services status
132
+ yarn stam services logs
133
+ ```
134
+
135
+ Stop them with:
136
+
137
+ ```bash
138
+ yarn stam services down
139
+ ```
140
+
141
+ ### Local SSO
142
+
143
+ Use `yarn stam sso config` to print the issuer, client credentials, test user, and example command.
144
+
145
+ Start Keycloak with the redirect URI copied from the app:
146
+
147
+ ```bash
148
+ yarn stam sso start "https://<organization-id>.api.stamhoofd/openid/callback"
149
+ ```
150
+
151
+ The command imports a local realm with the printed client and test user.
152
+
153
+ ### Tests
154
+
155
+ Unit tests start an isolated MySQL container, create `stamhoofd-tests`, run tests with the mapped `DB_PORT`, and remove the container afterward:
156
+
157
+ ```bash
158
+ yarn stam test unit
159
+ ```
160
+
161
+ Run Playwright tests with:
162
+
163
+ ```bash
164
+ yarn stam test e2e
165
+ ```
166
+
167
+ The e2e command keeps its MySQL container and data volume between runs so migrated worker databases can be reused. Reset that persistent e2e database with:
168
+
169
+ ```bash
170
+ yarn stam test e2e --clear
171
+ ```
172
+
173
+ Use `--workers <number>` to override Playwright's default worker count for a run.
174
+ Use `--extra` to include tests tagged `@extra`.
175
+
176
+ Run the full validation flow with:
177
+
178
+ ```bash
179
+ yarn stam check all
180
+ ```
181
+
182
+ ## For CLI Maintainers
183
+
184
+ The sections below are for contributors working on `shared/cli` itself rather than only using the CLI.
185
+
186
+ ### Architecture Overview
187
+
188
+ `shared/cli` is organized around a small set of responsibilities:
189
+
190
+ - `src/commands/`: oclif command entrypoints that parse flags and dispatch work.
191
+ - `src/workflows/`: multi-step flows such as machine setup or starting a full development session.
192
+ - `src/services/`: shared Docker service abstractions, service definitions, and service orchestration.
193
+ - `src/config/`: development configuration and generated infrastructure config such as Caddy routing.
194
+ - `src/context/`: workspace, instance, and port resolution.
195
+ - `src/runtime/`: process execution, output rendering, manifests, help rendering, and external CLI helpers.
196
+
197
+ The intended flow is:
198
+
199
+ 1. Commands parse user input.
200
+ 2. Commands create a `CliContext`.
201
+ 3. Commands call workflows, runtime helpers, or services.
202
+ 4. Workflows orchestrate long-running behavior, service startup, manifests, and output.
203
+ 5. Services encapsulate Docker-specific behavior.
204
+
205
+ Try to keep that direction intact. Commands should stay thin, workflows should own coordination, and runtime utilities should stay generic enough to be reused from multiple commands.
206
+
207
+ ### Runtime Concepts
208
+
209
+ Some runtime concepts show up across many commands and are worth understanding before changing behavior.
210
+
211
+ #### Instance Inference
212
+
213
+ The CLI computes a `CliContext` from:
214
+
215
+ - the repository root
216
+ - the selected environment
217
+ - the workspace name
218
+ - optional overrides such as `--name` or environment variables
219
+
220
+ That context decides the instance name, domain prefix, whether the instance is considered primary, and the port offset used by local apps.
221
+
222
+ #### Port Allocation
223
+
224
+ Base ports come from `src/context/ports.ts`.
225
+
226
+ For secondary instances, `src/context/instance.ts` and `src/context/port-allocation.ts` assign deterministic offsets so multiple clones of the repository can run at once. If a computed range is occupied, the CLI steps to the next bucket until it finds a free range or fails with a clear error.
227
+
228
+ #### Manifests
229
+
230
+ The CLI writes JSON manifests under `.development/cli/generated` to describe what is currently running.
231
+
232
+ - instance manifests let `stam status` and Caddy discover active local instances
233
+ - the shared services manifest records that shared infrastructure was started
234
+
235
+ When changing startup or shutdown behavior, keep manifest creation and cleanup in sync or the CLI will show stale instances or stale routes.
236
+
237
+ #### Output Flow
238
+
239
+ Long-running commands do not write directly to `console.log` unless they intentionally bypass the CLI output system. Instead they use runtime helpers so status lines, live output, tables, and command logging can coexist without corrupting terminal output.
240
+
241
+ When changing interactive output, check `src/runtime/live-output.ts`, `src/runtime/output-target.ts`, and `src/runtime/ux.ts` together.
242
+
243
+ ### Service Model
244
+
245
+ Shared infrastructure is modeled through `ServiceDefinition` in `src/services/service.ts`.
246
+
247
+ The common patterns are:
248
+
249
+ - `DockerService`: base class for services that start through `docker run`
250
+ - `SharedDockerService`: convenience base for shared services without per-command options
251
+ - `manager.ts`: orchestration for status, start, stop, restart, log tailing, and interactive tables
252
+ - `registry.ts`: the ordered list of shared services used by the CLI
253
+
254
+ The normal lifecycle is:
255
+
256
+ 1. Read current status.
257
+ 2. Optionally prepare files or derived config.
258
+ 3. Decide whether an existing container can be reused.
259
+ 4. Stop the old container if needed.
260
+ 5. Run setup hooks.
261
+ 6. Start the container.
262
+ 7. Run post-start hooks.
263
+ 8. Return any environment variables needed by callers.
264
+
265
+ When adding a service, keep Docker-specific behavior inside the service class instead of spreading it across commands or workflows.
266
+
267
+ As a rule of thumb:
268
+
269
+ - add a new service definition in `src/services/definitions/`
270
+ - register it in `src/services/registry.ts` if it is part of the shared baseline
271
+ - use `startServicesInteractive` or `restartServicesInteractive` when the command should show progress for multiple services
272
+ - use `startServices` or `stopServices` when the caller already controls user-facing output
273
+
274
+ ### Development Config Contract
275
+
276
+ `src/config/development-config.ts` is the main contract exported by `@stamhoofd/cli` for the rest of the monorepo.
277
+
278
+ It is responsible for resolving:
279
+
280
+ - local domains
281
+ - port numbers
282
+ - backend environment variables
283
+ - frontend and backend app environment objects
284
+ - environment-specific presets such as platform name or user mode
285
+
286
+ Prefer putting local-development defaults there first and reading the resolved config elsewhere instead of re-deriving values in commands, services, app bootstrapping, or generated infrastructure config.
287
+
288
+ Good candidates for this file:
289
+
290
+ - anything that should stay consistent across app startup, status output, Caddy routing, and service helpers
291
+ - environment-specific local development behavior
292
+ - values consumed by backend or frontend dev builds through `@stamhoofd/cli`
293
+
294
+ Bad candidates for this file:
295
+
296
+ - one-off command-only formatting
297
+ - transient workflow state
298
+ - Docker lifecycle logic
299
+ - generic runtime helpers that are unrelated to development configuration
300
+
301
+ ### Working On The CLI
302
+
303
+ `yarn install` builds `shared/cli` so normal CLI startup stays fast. When changing CLI source code, use `stam-dev` to rebuild before running:
304
+
305
+ ```bash
306
+ yarn stam-dev --help
307
+ ```
308
+
309
+ For CLI-only changes, run:
310
+
311
+ ```bash
312
+ yarn --cwd shared/cli -s build
313
+ yarn --cwd shared/cli -s lint
314
+ yarn --cwd shared/cli -s test
315
+ ```
316
+
317
+ CLI tests live next to source files as `*.test.ts`.
318
+
319
+ After changing CLI behavior, validate at least the package-local checks:
320
+
321
+ ```bash
322
+ yarn --cwd shared/cli -s test
323
+ yarn --cwd shared/cli -s build
324
+ ```
325
+
326
+ For command-surface changes, it is also useful to compare the generated help output with the README:
327
+
328
+ ```bash
329
+ yarn stam --help
330
+ yarn stam services --help
331
+ yarn stam clean --help
332
+ ```
333
+
334
+ ## Troubleshooting
335
+
336
+ Use `yarn stam setup` first. It checks Node, Docker, Caddy, DNS, and certificate trust.
337
+
338
+ - **The active Node.js version differs from `.nvmrc`**
339
+
340
+ Run `source .development/install-node.sh`. The script uses [fnm](https://github.com/Schniz/fnm) or [nvm](https://github.com/nvm-sh/nvm), whichever is available. `stam status` also reports this mismatch, and `stam dev` will stop before starting processes with the wrong version.
341
+
342
+ If that does not tell you enough, use the first matching case below.
343
+
344
+ - DNS names like `dashboard.stamhoofd` do not resolve:
345
+ Run `yarn stam setup dns`, then retry `yarn stam setup check`.
346
+ - `yarn stam setup` reports missing privileged port redirects on Linux:
347
+ Let the setup command apply the recommended `sudo iptables` rules, then retry.
348
+ - HTTPS works badly or the browser does not trust local certificates:
349
+ Run `yarn stam setup cert`, then retry `yarn stam setup check`.
350
+ - Docker commands fail or services do not start:
351
+ Start Docker, retry the command, and use `yarn stam services status` to confirm which service is still down.
352
+ - Caddy fails to reload or URLs do not open locally:
353
+ Check `yarn stam services status`, then try `yarn stam services restart`.
354
+ - URLs, instance names, or ports look wrong:
355
+ Run `yarn stam status`, `yarn stam config explain`, and check whether `--env`, `--name`, or environment variables such as `STAMHOOFD_WORKSPACE_NAME` are overriding the inferred instance.
356
+ - Two workspaces conflict on ports:
357
+ Check whether `STAMHOOFD_PORT_OFFSET` is forcing the same offset in multiple clones. Otherwise rerun the command and let automatic port allocation pick another bucket.
358
+ - Local database state is broken:
359
+ Use `yarn stam clean db` for the selected instance or `yarn stam clean all` if generated state is broadly stale.
360
+ - Shared services state is broken:
361
+ Use `yarn stam services restart`, or `yarn stam clean services` if volumes or generated service files need to be cleared manually.
362
+ - SSO redirect or Keycloak issues appear locally:
363
+ Re-run `yarn stam sso config`, make sure the redirect URI still ends in `/openid/callback`, then restart SSO with `yarn stam sso start "<redirect-uri>"`.
364
+ - Stale build or type errors keep appearing after code changes:
365
+ Run `yarn build:shared`, then retry the CLI command or app startup flow.
package/bin/stam.js ADDED
@@ -0,0 +1,19 @@
1
+ #!/usr/bin/env node
2
+ import { run } from '@oclif/core';
3
+
4
+ async function main() {
5
+ const args = process.argv.slice(2);
6
+
7
+ if (args.length === 0) {
8
+ await run(['--help'], import.meta.url);
9
+ return;
10
+ }
11
+
12
+ await run(args, import.meta.url);
13
+ }
14
+
15
+ main().catch((error) => {
16
+ const exitCode = typeof error?.exitCode === 'number' ? error.exitCode : 1;
17
+ console.error(error);
18
+ process.exitCode = exitCode;
19
+ });
@@ -0,0 +1,22 @@
1
+ import { Command } from '@oclif/core';
2
+ import type { CliContext } from './context/create-context.js';
3
+ export declare abstract class BaseCommand extends Command {
4
+ static verboseFlags: {
5
+ verbose: import("@oclif/core/interfaces").BooleanFlag<boolean>;
6
+ };
7
+ static environmentFlags: {
8
+ verbose: import("@oclif/core/interfaces").BooleanFlag<boolean>;
9
+ env: import("@oclif/core/interfaces").OptionFlag<string, import("@oclif/core/interfaces").CustomOptions>;
10
+ };
11
+ static instanceFlags: {
12
+ name: import("@oclif/core/interfaces").OptionFlag<string | undefined, import("@oclif/core/interfaces").CustomOptions>;
13
+ verbose: import("@oclif/core/interfaces").BooleanFlag<boolean>;
14
+ env: import("@oclif/core/interfaces").OptionFlag<string, import("@oclif/core/interfaces").CustomOptions>;
15
+ };
16
+ protected createContext(flags: {
17
+ env?: string;
18
+ name?: string;
19
+ verbose?: boolean;
20
+ }): Promise<CliContext>;
21
+ }
22
+ //# sourceMappingURL=base-command.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"base-command.d.ts","sourceRoot":"","sources":["../src/base-command.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,EAAS,MAAM,aAAa,CAAC;AAE7C,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,6BAA6B,CAAC;AAE9D,8BAAsB,WAAY,SAAQ,OAAO;IAC7C,MAAM,CAAC,YAAY;;MAEjB;IAEF,MAAM,CAAC,gBAAgB;;;MAGrB;IAEF,MAAM,CAAC,aAAa;;;;MAGlB;cAEc,aAAa,CAAC,KAAK,EAAE;QAAE,GAAG,CAAC,EAAE,MAAM,CAAC;QAAC,IAAI,CAAC,EAAE,MAAM,CAAC;QAAC,OAAO,CAAC,EAAE,OAAO,CAAA;KAAE,GAAG,OAAO,CAAC,UAAU,CAAC;CAOhH"}
@@ -0,0 +1,23 @@
1
+ import { Command, Flags } from '@oclif/core';
2
+ import { createContext } from './context/create-context.js';
3
+ export class BaseCommand extends Command {
4
+ static verboseFlags = {
5
+ verbose: Flags.boolean({ description: 'Print extra diagnostics while running', default: false }),
6
+ };
7
+ static environmentFlags = {
8
+ env: Flags.string({ description: 'Environment to use, such as stamhoofd or keeo', default: 'stamhoofd' }),
9
+ ...BaseCommand.verboseFlags,
10
+ };
11
+ static instanceFlags = {
12
+ ...BaseCommand.environmentFlags,
13
+ name: Flags.string({ description: 'Instance name to use instead of the inferred workspace name' }),
14
+ };
15
+ async createContext(flags) {
16
+ return await createContext({
17
+ env: flags.env ?? 'stamhoofd',
18
+ instanceName: flags.name,
19
+ verbose: flags.verbose ?? false,
20
+ });
21
+ }
22
+ }
23
+ //# sourceMappingURL=base-command.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"base-command.js","sourceRoot":"","sources":["../src/base-command.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,EAAE,KAAK,EAAE,MAAM,aAAa,CAAC;AAC7C,OAAO,EAAE,aAAa,EAAE,MAAM,6BAA6B,CAAC;AAG5D,MAAM,OAAgB,WAAY,SAAQ,OAAO;IAC7C,MAAM,CAAC,YAAY,GAAG;QAClB,OAAO,EAAE,KAAK,CAAC,OAAO,CAAC,EAAE,WAAW,EAAE,uCAAuC,EAAE,OAAO,EAAE,KAAK,EAAE,CAAC;KACnG,CAAC;IAEF,MAAM,CAAC,gBAAgB,GAAG;QACtB,GAAG,EAAE,KAAK,CAAC,MAAM,CAAC,EAAE,WAAW,EAAE,+CAA+C,EAAE,OAAO,EAAE,WAAW,EAAE,CAAC;QACzG,GAAG,WAAW,CAAC,YAAY;KAC9B,CAAC;IAEF,MAAM,CAAC,aAAa,GAAG;QACnB,GAAG,WAAW,CAAC,gBAAgB;QAC/B,IAAI,EAAE,KAAK,CAAC,MAAM,CAAC,EAAE,WAAW,EAAE,6DAA6D,EAAE,CAAC;KACrG,CAAC;IAEQ,KAAK,CAAC,aAAa,CAAC,KAAyD;QACnF,OAAO,MAAM,aAAa,CAAC;YACvB,GAAG,EAAE,KAAK,CAAC,GAAG,IAAI,WAAW;YAC7B,YAAY,EAAE,KAAK,CAAC,IAAI;YACxB,OAAO,EAAE,KAAK,CAAC,OAAO,IAAI,KAAK;SAClC,CAAC,CAAC;IACP,CAAC"}
@@ -0,0 +1,8 @@
1
+ export declare const verboseFlag: import("@oclif/core/interfaces").BooleanFlag<boolean>;
2
+ export declare const servicesOptionFlag: import("@oclif/core/interfaces").BooleanFlag<boolean>;
3
+ export declare const stripeFlag: import("@oclif/core/interfaces").BooleanFlag<boolean>;
4
+ export declare const yesFlag: import("@oclif/core/interfaces").BooleanFlag<boolean>;
5
+ export declare const dryRunFlag: import("@oclif/core/interfaces").BooleanFlag<boolean>;
6
+ export declare const openFlag: import("@oclif/core/interfaces").BooleanFlag<boolean>;
7
+ export declare const ciFlag: import("@oclif/core/interfaces").BooleanFlag<boolean>;
8
+ //# sourceMappingURL=command-flags.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"command-flags.d.ts","sourceRoot":"","sources":["../src/command-flags.ts"],"names":[],"mappings":"AAEA,eAAO,MAAM,WAAW,uDAGtB,CAAC;AAEH,eAAO,MAAM,kBAAkB,uDAG7B,CAAC;AAEH,eAAO,MAAM,UAAU,uDAIrB,CAAC;AAEH,eAAO,MAAM,OAAO,uDAIlB,CAAC;AAEH,eAAO,MAAM,UAAU,uDAGrB,CAAC;AAEH,eAAO,MAAM,QAAQ,uDAGnB,CAAC;AAEH,eAAO,MAAM,MAAM,uDAGjB,CAAC"}
@@ -0,0 +1,32 @@
1
+ import { Flags } from '@oclif/core';
2
+ export const verboseFlag = Flags.boolean({
3
+ description: 'Print extra diagnostics while running',
4
+ default: false,
5
+ });
6
+ export const servicesOptionFlag = Flags.boolean({
7
+ allowNo: true,
8
+ description: 'Start shared services before the selected target',
9
+ });
10
+ export const stripeFlag = Flags.boolean({
11
+ allowNo: true,
12
+ default: true,
13
+ description: 'Start a Stripe listener for the selected instance',
14
+ });
15
+ export const yesFlag = Flags.boolean({
16
+ char: 'y',
17
+ default: false,
18
+ description: 'Skip confirmation prompts',
19
+ });
20
+ export const dryRunFlag = Flags.boolean({
21
+ default: false,
22
+ description: 'Preview changes without applying them',
23
+ });
24
+ export const openFlag = Flags.boolean({
25
+ default: false,
26
+ description: 'Open the dashboard in your browser',
27
+ });
28
+ export const ciFlag = Flags.boolean({
29
+ default: false,
30
+ description: 'Run in non-interactive CI-style mode',
31
+ });
32
+ //# sourceMappingURL=command-flags.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"command-flags.js","sourceRoot":"","sources":["../src/command-flags.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,EAAE,MAAM,aAAa,CAAC;AAEpC,MAAM,CAAC,MAAM,WAAW,GAAG,KAAK,CAAC,OAAO,CAAC;IACrC,WAAW,EAAE,uCAAuC;IACpD,OAAO,EAAE,KAAK;CACjB,CAAC,CAAC;AAEH,MAAM,CAAC,MAAM,kBAAkB,GAAG,KAAK,CAAC,OAAO,CAAC;IAC5C,OAAO,EAAE,IAAI;IACb,WAAW,EAAE,kDAAkD;CAClE,CAAC,CAAC;AAEH,MAAM,CAAC,MAAM,UAAU,GAAG,KAAK,CAAC,OAAO,CAAC;IACpC,OAAO,EAAE,IAAI;IACb,OAAO,EAAE,IAAI;IACb,WAAW,EAAE,mDAAmD;CACnE,CAAC,CAAC;AAEH,MAAM,CAAC,MAAM,OAAO,GAAG,KAAK,CAAC,OAAO,CAAC;IACjC,IAAI,EAAE,GAAG;IACT,OAAO,EAAE,KAAK;IACd,WAAW,EAAE,2BAA2B;CAC3C,CAAC,CAAC;AAEH,MAAM,CAAC,MAAM,UAAU,GAAG,KAAK,CAAC,OAAO,CAAC;IACpC,OAAO,EAAE,KAAK;IACd,WAAW,EAAE,uCAAuC;CACvD,CAAC,CAAC;AAEH,MAAM,CAAC,MAAM,QAAQ,GAAG,KAAK,CAAC,OAAO,CAAC;IAClC,OAAO,EAAE,KAAK;IACd,WAAW,EAAE,oCAAoC;CACpD,CAAC,CAAC;AAEH,MAAM,CAAC,MAAM,MAAM,GAAG,KAAK,CAAC,OAAO,CAAC;IAChC,OAAO,EAAE,KAAK;IACd,WAAW,EAAE,sCAAsC;CACtD,CAAC,CAAC"}
@@ -0,0 +1,12 @@
1
+ import { BaseCommand } from '../base-command.js';
2
+ export default class Build extends BaseCommand {
3
+ static summary: string;
4
+ static description: string;
5
+ static examples: string[];
6
+ static flags: {
7
+ verbose: import("@oclif/core/interfaces").BooleanFlag<boolean>;
8
+ env: import("@oclif/core/interfaces").OptionFlag<string, import("@oclif/core/interfaces").CustomOptions>;
9
+ };
10
+ run(): Promise<void>;
11
+ }
12
+ //# sourceMappingURL=build.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"build.d.ts","sourceRoot":"","sources":["../../src/commands/build.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,WAAW,EAAE,MAAM,oBAAoB,CAAC;AAGjD,MAAM,CAAC,OAAO,OAAO,KAAM,SAAQ,WAAW;IAC1C,MAAM,CAAC,OAAO,SAAkC;IAChD,MAAM,CAAC,WAAW,SAAgH;IAClI,MAAM,CAAC,QAAQ,WAGb;IACF,MAAM,CAAC,KAAK;;;MAAgC;IAEtC,GAAG,IAAI,OAAO,CAAC,IAAI,CAAC;CAI7B"}
@@ -0,0 +1,16 @@
1
+ import { BaseCommand } from '../base-command.js';
2
+ import { buildAll } from '../runtime/monorepo-runner.js';
3
+ export default class Build extends BaseCommand {
4
+ static summary = 'Build all Stamhoofd packages';
5
+ static description = 'Use this when generated artifacts are stale or before running broader checks that depend on a clean build.';
6
+ static examples = [
7
+ 'stam build --env keeo',
8
+ 'stam build --verbose',
9
+ ];
10
+ static flags = BaseCommand.environmentFlags;
11
+ async run() {
12
+ const { flags } = await this.parse(Build);
13
+ await buildAll(await this.createContext(flags));
14
+ }
15
+ }
16
+ //# sourceMappingURL=build.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"build.js","sourceRoot":"","sources":["../../src/commands/build.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,WAAW,EAAE,MAAM,oBAAoB,CAAC;AACjD,OAAO,EAAE,QAAQ,EAAE,MAAM,+BAA+B,CAAC;AAEzD,MAAM,CAAC,OAAO,OAAO,KAAM,SAAQ,WAAW;IAC1C,MAAM,CAAC,OAAO,GAAG,8BAA8B,CAAC;IAChD,MAAM,CAAC,WAAW,GAAG,4GAA4G,CAAC;IAClI,MAAM,CAAC,QAAQ,GAAG;QACd,uBAAuB;QACvB,sBAAsB;KACzB,CAAC;IACF,MAAM,CAAC,KAAK,GAAG,WAAW,CAAC,gBAAgB,CAAC;IAE5C,KAAK,CAAC,GAAG;QACL,MAAM,EAAE,KAAK,EAAE,GAAG,MAAM,IAAI,CAAC,KAAK,CAAC,KAAK,CAAC,CAAC;QAC1C,MAAM,QAAQ,CAAC,MAAM,IAAI,CAAC,aAAa,CAAC,KAAK,CAAC,CAAC,CAAC;IACpD,CAAC"}
@@ -0,0 +1,12 @@
1
+ import { BaseCommand } from '../../base-command.js';
2
+ export default class CheckAll extends BaseCommand {
3
+ static summary: string;
4
+ static description: string;
5
+ static examples: string[];
6
+ static flags: {
7
+ verbose: import("@oclif/core/interfaces").BooleanFlag<boolean>;
8
+ env: import("@oclif/core/interfaces").OptionFlag<string, import("@oclif/core/interfaces").CustomOptions>;
9
+ };
10
+ run(): Promise<void>;
11
+ }
12
+ //# sourceMappingURL=all.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"all.d.ts","sourceRoot":"","sources":["../../../src/commands/check/all.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,WAAW,EAAE,MAAM,uBAAuB,CAAC;AAGpD,MAAM,CAAC,OAAO,OAAO,QAAS,SAAQ,WAAW;IAC7C,MAAM,CAAC,OAAO,SAA+B;IAC7C,MAAM,CAAC,WAAW,SAA2G;IAC7H,MAAM,CAAC,QAAQ,WAGb;IACF,MAAM,CAAC,KAAK;;;MAAgC;IAEtC,GAAG,IAAI,OAAO,CAAC,IAAI,CAAC;CAS7B"}
@@ -0,0 +1,21 @@
1
+ import { BaseCommand } from '../../base-command.js';
2
+ import { buildAll, lint, testE2e, testUnit, typecheck } from '../../runtime/monorepo-runner.js';
3
+ export default class CheckAll extends BaseCommand {
4
+ static summary = 'Run all validation checks';
5
+ static description = 'Use this before pushing when you want roughly the same broad safety net as the main automated checks.';
6
+ static examples = [
7
+ 'stam check all',
8
+ 'stam check all --env keeo',
9
+ ];
10
+ static flags = BaseCommand.environmentFlags;
11
+ async run() {
12
+ const { flags } = await this.parse(CheckAll);
13
+ const context = await this.createContext(flags);
14
+ await buildAll(context);
15
+ await lint(context);
16
+ await typecheck(context);
17
+ await testUnit(context, true);
18
+ await testE2e(context, { ci: true, clear: false, ui: false });
19
+ }
20
+ }
21
+ //# sourceMappingURL=all.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"all.js","sourceRoot":"","sources":["../../../src/commands/check/all.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,WAAW,EAAE,MAAM,uBAAuB,CAAC;AACpD,OAAO,EAAE,QAAQ,EAAE,IAAI,EAAE,OAAO,EAAE,QAAQ,EAAE,SAAS,EAAE,MAAM,kCAAkC,CAAC;AAEhG,MAAM,CAAC,OAAO,OAAO,QAAS,SAAQ,WAAW;IAC7C,MAAM,CAAC,OAAO,GAAG,2BAA2B,CAAC;IAC7C,MAAM,CAAC,WAAW,GAAG,uGAAuG,CAAC;IAC7H,MAAM,CAAC,QAAQ,GAAG;QACd,gBAAgB;QAChB,2BAA2B;KAC9B,CAAC;IACF,MAAM,CAAC,KAAK,GAAG,WAAW,CAAC,gBAAgB,CAAC;IAE5C,KAAK,CAAC,GAAG;QACL,MAAM,EAAE,KAAK,EAAE,GAAG,MAAM,IAAI,CAAC,KAAK,CAAC,QAAQ,CAAC,CAAC;QAC7C,MAAM,OAAO,GAAG,MAAM,IAAI,CAAC,aAAa,CAAC,KAAK,CAAC,CAAC;QAChD,MAAM,QAAQ,CAAC,OAAO,CAAC,CAAC;QACxB,MAAM,IAAI,CAAC,OAAO,CAAC,CAAC;QACpB,MAAM,SAAS,CAAC,OAAO,CAAC,CAAC;QACzB,MAAM,QAAQ,CAAC,OAAO,EAAE,IAAI,CAAC,CAAC;QAC9B,MAAM,OAAO,CAAC,OAAO,EAAE,EAAE,EAAE,EAAE,IAAI,EAAE,KAAK,EAAE,KAAK,EAAE,EAAE,EAAE,KAAK,EAAE,CAAC,CAAC;IAClE,CAAC"}
@@ -0,0 +1,8 @@
1
+ import { Command } from '@oclif/core';
2
+ export default class Check extends Command {
3
+ static summary: string;
4
+ static description: string;
5
+ static examples: string[];
6
+ run(): Promise<void>;
7
+ }
8
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/commands/check/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,EAAE,MAAM,aAAa,CAAC;AAGtC,MAAM,CAAC,OAAO,OAAO,KAAM,SAAQ,OAAO;IACtC,MAAM,CAAC,OAAO,SAA2C;IACzD,MAAM,CAAC,WAAW,SAAmH;IACrI,MAAM,CAAC,QAAQ,WAIb;IAEI,GAAG,IAAI,OAAO,CAAC,IAAI,CAAC;CAG7B"}
@@ -0,0 +1,15 @@
1
+ import { Command } from '@oclif/core';
2
+ import { showHelp } from '../../runtime/show-help.js';
3
+ export default class Check extends Command {
4
+ static summary = 'Run build, lint, typecheck, and tests';
5
+ static description = 'Use these commands to run build, lint, type checks, or the full validation suite locally before opening a PR.';
6
+ static examples = [
7
+ 'stam check lint',
8
+ 'stam check typecheck',
9
+ 'stam check all',
10
+ ];
11
+ async run() {
12
+ await showHelp(this.config, ['check']);
13
+ }
14
+ }
15
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/commands/check/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,EAAE,MAAM,aAAa,CAAC;AACtC,OAAO,EAAE,QAAQ,EAAE,MAAM,4BAA4B,CAAC;AAEtD,MAAM,CAAC,OAAO,OAAO,KAAM,SAAQ,OAAO;IACtC,MAAM,CAAC,OAAO,GAAG,uCAAuC,CAAC;IACzD,MAAM,CAAC,WAAW,GAAG,+GAA+G,CAAC;IACrI,MAAM,CAAC,QAAQ,GAAG;QACd,iBAAiB;QACjB,sBAAsB;QACtB,gBAAgB;KACnB,CAAC;IAEF,KAAK,CAAC,GAAG;QACL,MAAM,QAAQ,CAAC,IAAI,CAAC,MAAM,EAAE,CAAC,OAAO,CAAC,CAAC,CAAC;IAC3C,CAAC"}