@take-out/cli 0.0.39

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 (331) hide show
  1. package/LICENSE +21 -0
  2. package/README.md +274 -0
  3. package/cli.mjs +3 -0
  4. package/dist/cjs/cli.cjs +71 -0
  5. package/dist/cjs/cli.js +70 -0
  6. package/dist/cjs/cli.js.map +6 -0
  7. package/dist/cjs/cli.native.js +79 -0
  8. package/dist/cjs/cli.native.js.map +6 -0
  9. package/dist/cjs/commands/changed.cjs +212 -0
  10. package/dist/cjs/commands/changed.js +214 -0
  11. package/dist/cjs/commands/changed.js.map +6 -0
  12. package/dist/cjs/commands/changed.native.js +289 -0
  13. package/dist/cjs/commands/changed.native.js.map +6 -0
  14. package/dist/cjs/commands/docs.cjs +388 -0
  15. package/dist/cjs/commands/docs.js +313 -0
  16. package/dist/cjs/commands/docs.js.map +6 -0
  17. package/dist/cjs/commands/docs.native.js +476 -0
  18. package/dist/cjs/commands/docs.native.js.map +6 -0
  19. package/dist/cjs/commands/env-setup.cjs +90 -0
  20. package/dist/cjs/commands/env-setup.js +78 -0
  21. package/dist/cjs/commands/env-setup.js.map +6 -0
  22. package/dist/cjs/commands/env-setup.native.js +85 -0
  23. package/dist/cjs/commands/env-setup.native.js.map +6 -0
  24. package/dist/cjs/commands/onboard.cjs +479 -0
  25. package/dist/cjs/commands/onboard.js +631 -0
  26. package/dist/cjs/commands/onboard.js.map +6 -0
  27. package/dist/cjs/commands/onboard.native.js +608 -0
  28. package/dist/cjs/commands/onboard.native.js.map +6 -0
  29. package/dist/cjs/commands/run.cjs +148 -0
  30. package/dist/cjs/commands/run.js +116 -0
  31. package/dist/cjs/commands/run.js.map +6 -0
  32. package/dist/cjs/commands/run.native.js +140 -0
  33. package/dist/cjs/commands/run.native.js.map +6 -0
  34. package/dist/cjs/commands/script.cjs +379 -0
  35. package/dist/cjs/commands/script.js +339 -0
  36. package/dist/cjs/commands/script.js.map +6 -0
  37. package/dist/cjs/commands/script.native.js +449 -0
  38. package/dist/cjs/commands/script.native.js.map +6 -0
  39. package/dist/cjs/commands/sync.cjs +190 -0
  40. package/dist/cjs/commands/sync.js +168 -0
  41. package/dist/cjs/commands/sync.js.map +6 -0
  42. package/dist/cjs/commands/sync.native.js +211 -0
  43. package/dist/cjs/commands/sync.native.js.map +6 -0
  44. package/dist/cjs/constants/ascii.cjs +36 -0
  45. package/dist/cjs/constants/ascii.js +30 -0
  46. package/dist/cjs/constants/ascii.js.map +6 -0
  47. package/dist/cjs/constants/ascii.native.js +36 -0
  48. package/dist/cjs/constants/ascii.native.js.map +6 -0
  49. package/dist/cjs/index.cjs +64 -0
  50. package/dist/cjs/index.js +55 -0
  51. package/dist/cjs/index.js.map +6 -0
  52. package/dist/cjs/index.native.js +94 -0
  53. package/dist/cjs/index.native.js.map +6 -0
  54. package/dist/cjs/types.cjs +16 -0
  55. package/dist/cjs/types.js +14 -0
  56. package/dist/cjs/types.js.map +6 -0
  57. package/dist/cjs/types.native.js +15 -0
  58. package/dist/cjs/types.native.js.map +6 -0
  59. package/dist/cjs/utils/env-categories.cjs +272 -0
  60. package/dist/cjs/utils/env-categories.js +296 -0
  61. package/dist/cjs/utils/env-categories.js.map +6 -0
  62. package/dist/cjs/utils/env-categories.native.js +317 -0
  63. package/dist/cjs/utils/env-categories.native.js.map +6 -0
  64. package/dist/cjs/utils/env-setup.cjs +181 -0
  65. package/dist/cjs/utils/env-setup.js +190 -0
  66. package/dist/cjs/utils/env-setup.js.map +6 -0
  67. package/dist/cjs/utils/env-setup.native.js +264 -0
  68. package/dist/cjs/utils/env-setup.native.js.map +6 -0
  69. package/dist/cjs/utils/env.cjs +118 -0
  70. package/dist/cjs/utils/env.js +97 -0
  71. package/dist/cjs/utils/env.js.map +6 -0
  72. package/dist/cjs/utils/env.native.js +128 -0
  73. package/dist/cjs/utils/env.native.js.map +6 -0
  74. package/dist/cjs/utils/files.cjs +215 -0
  75. package/dist/cjs/utils/files.js +164 -0
  76. package/dist/cjs/utils/files.js.map +6 -0
  77. package/dist/cjs/utils/files.native.js +266 -0
  78. package/dist/cjs/utils/files.native.js.map +6 -0
  79. package/dist/cjs/utils/parallel-runner.cjs +99 -0
  80. package/dist/cjs/utils/parallel-runner.js +84 -0
  81. package/dist/cjs/utils/parallel-runner.js.map +6 -0
  82. package/dist/cjs/utils/parallel-runner.native.js +123 -0
  83. package/dist/cjs/utils/parallel-runner.native.js.map +6 -0
  84. package/dist/cjs/utils/ports.cjs +101 -0
  85. package/dist/cjs/utils/ports.js +81 -0
  86. package/dist/cjs/utils/ports.js.map +6 -0
  87. package/dist/cjs/utils/ports.native.js +130 -0
  88. package/dist/cjs/utils/ports.native.js.map +6 -0
  89. package/dist/cjs/utils/prerequisites.cjs +119 -0
  90. package/dist/cjs/utils/prerequisites.js +107 -0
  91. package/dist/cjs/utils/prerequisites.js.map +6 -0
  92. package/dist/cjs/utils/prerequisites.native.js +127 -0
  93. package/dist/cjs/utils/prerequisites.native.js.map +6 -0
  94. package/dist/cjs/utils/prompts.cjs +161 -0
  95. package/dist/cjs/utils/prompts.js +162 -0
  96. package/dist/cjs/utils/prompts.js.map +6 -0
  97. package/dist/cjs/utils/prompts.native.js +179 -0
  98. package/dist/cjs/utils/prompts.native.js.map +6 -0
  99. package/dist/cjs/utils/script-listing.cjs +113 -0
  100. package/dist/cjs/utils/script-listing.js +108 -0
  101. package/dist/cjs/utils/script-listing.js.map +6 -0
  102. package/dist/cjs/utils/script-listing.native.js +174 -0
  103. package/dist/cjs/utils/script-listing.native.js.map +6 -0
  104. package/dist/cjs/utils/sync.cjs +85 -0
  105. package/dist/cjs/utils/sync.js +70 -0
  106. package/dist/cjs/utils/sync.js.map +6 -0
  107. package/dist/cjs/utils/sync.native.js +84 -0
  108. package/dist/cjs/utils/sync.native.js.map +6 -0
  109. package/dist/cjs/utils/welcome.cjs +50 -0
  110. package/dist/cjs/utils/welcome.js +42 -0
  111. package/dist/cjs/utils/welcome.js.map +6 -0
  112. package/dist/cjs/utils/welcome.native.js +47 -0
  113. package/dist/cjs/utils/welcome.native.js.map +6 -0
  114. package/dist/esm/cli.js +79 -0
  115. package/dist/esm/cli.js.map +6 -0
  116. package/dist/esm/cli.mjs +71 -0
  117. package/dist/esm/cli.mjs.map +1 -0
  118. package/dist/esm/cli.native.js +69 -0
  119. package/dist/esm/cli.native.js.map +1 -0
  120. package/dist/esm/commands/changed.js +194 -0
  121. package/dist/esm/commands/changed.js.map +6 -0
  122. package/dist/esm/commands/changed.mjs +178 -0
  123. package/dist/esm/commands/changed.mjs.map +1 -0
  124. package/dist/esm/commands/changed.native.js +273 -0
  125. package/dist/esm/commands/changed.native.js.map +1 -0
  126. package/dist/esm/commands/docs.js +306 -0
  127. package/dist/esm/commands/docs.js.map +6 -0
  128. package/dist/esm/commands/docs.mjs +353 -0
  129. package/dist/esm/commands/docs.mjs.map +1 -0
  130. package/dist/esm/commands/docs.native.js +516 -0
  131. package/dist/esm/commands/docs.native.js.map +1 -0
  132. package/dist/esm/commands/env-setup.js +56 -0
  133. package/dist/esm/commands/env-setup.js.map +6 -0
  134. package/dist/esm/commands/env-setup.mjs +56 -0
  135. package/dist/esm/commands/env-setup.mjs.map +1 -0
  136. package/dist/esm/commands/env-setup.native.js +59 -0
  137. package/dist/esm/commands/env-setup.native.js.map +1 -0
  138. package/dist/esm/commands/onboard.js +645 -0
  139. package/dist/esm/commands/onboard.js.map +6 -0
  140. package/dist/esm/commands/onboard.mjs +445 -0
  141. package/dist/esm/commands/onboard.mjs.map +1 -0
  142. package/dist/esm/commands/onboard.native.js +584 -0
  143. package/dist/esm/commands/onboard.native.js.map +1 -0
  144. package/dist/esm/commands/run.js +95 -0
  145. package/dist/esm/commands/run.js.map +6 -0
  146. package/dist/esm/commands/run.mjs +114 -0
  147. package/dist/esm/commands/run.mjs.map +1 -0
  148. package/dist/esm/commands/run.native.js +133 -0
  149. package/dist/esm/commands/run.native.js.map +1 -0
  150. package/dist/esm/commands/script.js +338 -0
  151. package/dist/esm/commands/script.js.map +6 -0
  152. package/dist/esm/commands/script.mjs +336 -0
  153. package/dist/esm/commands/script.mjs.map +1 -0
  154. package/dist/esm/commands/script.native.js +445 -0
  155. package/dist/esm/commands/script.native.js.map +1 -0
  156. package/dist/esm/commands/sync.js +158 -0
  157. package/dist/esm/commands/sync.js.map +6 -0
  158. package/dist/esm/commands/sync.mjs +155 -0
  159. package/dist/esm/commands/sync.mjs.map +1 -0
  160. package/dist/esm/commands/sync.native.js +173 -0
  161. package/dist/esm/commands/sync.native.js.map +1 -0
  162. package/dist/esm/constants/ascii.js +14 -0
  163. package/dist/esm/constants/ascii.js.map +6 -0
  164. package/dist/esm/constants/ascii.mjs +12 -0
  165. package/dist/esm/constants/ascii.mjs.map +1 -0
  166. package/dist/esm/constants/ascii.native.js +12 -0
  167. package/dist/esm/constants/ascii.native.js.map +1 -0
  168. package/dist/esm/index.js +83 -0
  169. package/dist/esm/index.js.map +6 -0
  170. package/dist/esm/index.mjs +7 -0
  171. package/dist/esm/index.mjs.map +1 -0
  172. package/dist/esm/index.native.js +7 -0
  173. package/dist/esm/index.native.js.map +1 -0
  174. package/dist/esm/types.js +1 -0
  175. package/dist/esm/types.js.map +6 -0
  176. package/dist/esm/types.mjs +2 -0
  177. package/dist/esm/types.mjs.map +1 -0
  178. package/dist/esm/types.native.js +2 -0
  179. package/dist/esm/types.native.js.map +1 -0
  180. package/dist/esm/utils/env-categories.js +272 -0
  181. package/dist/esm/utils/env-categories.js.map +6 -0
  182. package/dist/esm/utils/env-categories.mjs +233 -0
  183. package/dist/esm/utils/env-categories.mjs.map +1 -0
  184. package/dist/esm/utils/env-categories.native.js +246 -0
  185. package/dist/esm/utils/env-categories.native.js.map +1 -0
  186. package/dist/esm/utils/env-setup.js +173 -0
  187. package/dist/esm/utils/env-setup.js.map +6 -0
  188. package/dist/esm/utils/env-setup.mjs +146 -0
  189. package/dist/esm/utils/env-setup.mjs.map +1 -0
  190. package/dist/esm/utils/env-setup.native.js +243 -0
  191. package/dist/esm/utils/env-setup.native.js.map +1 -0
  192. package/dist/esm/utils/env.js +83 -0
  193. package/dist/esm/utils/env.js.map +6 -0
  194. package/dist/esm/utils/env.mjs +90 -0
  195. package/dist/esm/utils/env.mjs.map +1 -0
  196. package/dist/esm/utils/env.native.js +99 -0
  197. package/dist/esm/utils/env.native.js.map +1 -0
  198. package/dist/esm/utils/files.js +150 -0
  199. package/dist/esm/utils/files.js.map +6 -0
  200. package/dist/esm/utils/files.mjs +187 -0
  201. package/dist/esm/utils/files.mjs.map +1 -0
  202. package/dist/esm/utils/files.native.js +247 -0
  203. package/dist/esm/utils/files.native.js.map +1 -0
  204. package/dist/esm/utils/parallel-runner.js +69 -0
  205. package/dist/esm/utils/parallel-runner.js.map +6 -0
  206. package/dist/esm/utils/parallel-runner.mjs +76 -0
  207. package/dist/esm/utils/parallel-runner.mjs.map +1 -0
  208. package/dist/esm/utils/parallel-runner.native.js +109 -0
  209. package/dist/esm/utils/parallel-runner.native.js.map +1 -0
  210. package/dist/esm/utils/ports.js +65 -0
  211. package/dist/esm/utils/ports.js.map +6 -0
  212. package/dist/esm/utils/ports.mjs +74 -0
  213. package/dist/esm/utils/ports.mjs.map +1 -0
  214. package/dist/esm/utils/ports.native.js +93 -0
  215. package/dist/esm/utils/ports.native.js.map +1 -0
  216. package/dist/esm/utils/prerequisites.js +91 -0
  217. package/dist/esm/utils/prerequisites.js.map +6 -0
  218. package/dist/esm/utils/prerequisites.mjs +91 -0
  219. package/dist/esm/utils/prerequisites.mjs.map +1 -0
  220. package/dist/esm/utils/prerequisites.native.js +97 -0
  221. package/dist/esm/utils/prerequisites.native.js.map +1 -0
  222. package/dist/esm/utils/prompts.js +139 -0
  223. package/dist/esm/utils/prompts.js.map +6 -0
  224. package/dist/esm/utils/prompts.mjs +112 -0
  225. package/dist/esm/utils/prompts.mjs.map +1 -0
  226. package/dist/esm/utils/prompts.native.js +115 -0
  227. package/dist/esm/utils/prompts.native.js.map +1 -0
  228. package/dist/esm/utils/script-listing.js +91 -0
  229. package/dist/esm/utils/script-listing.js.map +6 -0
  230. package/dist/esm/utils/script-listing.mjs +76 -0
  231. package/dist/esm/utils/script-listing.mjs.map +1 -0
  232. package/dist/esm/utils/script-listing.native.js +151 -0
  233. package/dist/esm/utils/script-listing.native.js.map +1 -0
  234. package/dist/esm/utils/sync.js +50 -0
  235. package/dist/esm/utils/sync.js.map +6 -0
  236. package/dist/esm/utils/sync.mjs +48 -0
  237. package/dist/esm/utils/sync.mjs.map +1 -0
  238. package/dist/esm/utils/sync.native.js +53 -0
  239. package/dist/esm/utils/sync.native.js.map +1 -0
  240. package/dist/esm/utils/welcome.js +21 -0
  241. package/dist/esm/utils/welcome.js.map +6 -0
  242. package/dist/esm/utils/welcome.mjs +15 -0
  243. package/dist/esm/utils/welcome.mjs.map +1 -0
  244. package/dist/esm/utils/welcome.native.js +18 -0
  245. package/dist/esm/utils/welcome.native.js.map +1 -0
  246. package/docs/aggregates.md +579 -0
  247. package/docs/cloudflare-dev-tunnel.md +41 -0
  248. package/docs/database.md +203 -0
  249. package/docs/docs.md +8 -0
  250. package/docs/emitters.md +562 -0
  251. package/docs/hot-updater.md +223 -0
  252. package/docs/native-hot-update.md +252 -0
  253. package/docs/one-components.md +234 -0
  254. package/docs/one-hooks.md +570 -0
  255. package/docs/one-routes.md +660 -0
  256. package/docs/package-json.md +115 -0
  257. package/docs/react-native-navigation-flow.md +184 -0
  258. package/docs/scripts.md +147 -0
  259. package/docs/sync-prompt.md +208 -0
  260. package/docs/tamagui.md +478 -0
  261. package/docs/testing-integration.md +564 -0
  262. package/docs/triggers.md +450 -0
  263. package/docs/zero.md +719 -0
  264. package/package.json +76 -0
  265. package/scripts/seed.ts +209 -0
  266. package/src/cli.ts +147 -0
  267. package/src/commands/changed.ts +313 -0
  268. package/src/commands/docs.ts +582 -0
  269. package/src/commands/env-setup.ts +69 -0
  270. package/src/commands/onboard.ts +1391 -0
  271. package/src/commands/run.ts +173 -0
  272. package/src/commands/script.ts +587 -0
  273. package/src/commands/sync.ts +305 -0
  274. package/src/constants/ascii.ts +17 -0
  275. package/src/index.ts +63 -0
  276. package/src/types.ts +59 -0
  277. package/src/utils/env-categories.ts +245 -0
  278. package/src/utils/env-setup.ts +338 -0
  279. package/src/utils/env.ts +127 -0
  280. package/src/utils/files.ts +302 -0
  281. package/src/utils/parallel-runner.ts +129 -0
  282. package/src/utils/ports.ts +77 -0
  283. package/src/utils/prerequisites.ts +137 -0
  284. package/src/utils/prompts.ts +197 -0
  285. package/src/utils/script-listing.ts +214 -0
  286. package/src/utils/sync.ts +101 -0
  287. package/src/withOpSqliteStatic.cjs +51 -0
  288. package/types/cli.d.ts +7 -0
  289. package/types/cli.d.ts.map +1 -0
  290. package/types/commands/changed.d.ts +14 -0
  291. package/types/commands/changed.d.ts.map +1 -0
  292. package/types/commands/docs.d.ts +5 -0
  293. package/types/commands/docs.d.ts.map +1 -0
  294. package/types/commands/env-setup.d.ts +25 -0
  295. package/types/commands/env-setup.d.ts.map +1 -0
  296. package/types/commands/onboard.d.ts +16 -0
  297. package/types/commands/onboard.d.ts.map +1 -0
  298. package/types/commands/run.d.ts +8 -0
  299. package/types/commands/run.d.ts.map +1 -0
  300. package/types/commands/script.d.ts +28 -0
  301. package/types/commands/script.d.ts.map +1 -0
  302. package/types/commands/sync.d.ts +5 -0
  303. package/types/commands/sync.d.ts.map +1 -0
  304. package/types/constants/ascii.d.ts +6 -0
  305. package/types/constants/ascii.d.ts.map +1 -0
  306. package/types/index.d.ts +12 -0
  307. package/types/index.d.ts.map +1 -0
  308. package/types/types.d.ts +54 -0
  309. package/types/types.d.ts.map +1 -0
  310. package/types/utils/env-categories.d.ts +8 -0
  311. package/types/utils/env-categories.d.ts.map +1 -0
  312. package/types/utils/env-setup.d.ts +10 -0
  313. package/types/utils/env-setup.d.ts.map +1 -0
  314. package/types/utils/env.d.ts +19 -0
  315. package/types/utils/env.d.ts.map +1 -0
  316. package/types/utils/files.d.ts +47 -0
  317. package/types/utils/files.d.ts.map +1 -0
  318. package/types/utils/parallel-runner.d.ts +15 -0
  319. package/types/utils/parallel-runner.d.ts.map +1 -0
  320. package/types/utils/ports.d.ts +16 -0
  321. package/types/utils/ports.d.ts.map +1 -0
  322. package/types/utils/prerequisites.d.ts +11 -0
  323. package/types/utils/prerequisites.d.ts.map +1 -0
  324. package/types/utils/prompts.d.ts +30 -0
  325. package/types/utils/prompts.d.ts.map +1 -0
  326. package/types/utils/script-listing.d.ts +7 -0
  327. package/types/utils/script-listing.d.ts.map +1 -0
  328. package/types/utils/sync.d.ts +16 -0
  329. package/types/utils/sync.d.ts.map +1 -0
  330. package/types/utils/welcome.d.ts +6 -0
  331. package/types/utils/welcome.d.ts.map +1 -0
@@ -0,0 +1,55 @@
1
+ var __defProp = Object.defineProperty;
2
+ var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
3
+ var __getOwnPropNames = Object.getOwnPropertyNames;
4
+ var __hasOwnProp = Object.prototype.hasOwnProperty;
5
+ var __export = (target, all) => {
6
+ for (var name in all)
7
+ __defProp(target, name, { get: all[name], enumerable: !0 });
8
+ }, __copyProps = (to, from, except, desc) => {
9
+ if (from && typeof from == "object" || typeof from == "function")
10
+ for (let key of __getOwnPropNames(from))
11
+ !__hasOwnProp.call(to, key) && key !== except && __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
12
+ return to;
13
+ };
14
+ var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: !0 }), mod);
15
+ var index_exports = {};
16
+ __export(index_exports, {
17
+ TAKEOUT_PORTS: () => import_ports.TAKEOUT_PORTS,
18
+ checkAllPorts: () => import_ports.checkAllPorts,
19
+ checkAllPrerequisites: () => import_prerequisites.checkAllPrerequisites,
20
+ checkBun: () => import_prerequisites.checkBun,
21
+ checkDocker: () => import_prerequisites.checkDocker,
22
+ checkGit: () => import_prerequisites.checkGit,
23
+ checkNode: () => import_prerequisites.checkNode,
24
+ checkOnboarded: () => import_files.checkOnboarded,
25
+ checkPort: () => import_ports.checkPort,
26
+ confirmContinue: () => import_prompts.confirmContinue,
27
+ copyEnvFile: () => import_env.copyEnvFile,
28
+ createEnvLocal: () => import_env.createEnvLocal,
29
+ displayOutro: () => import_prompts.displayOutro,
30
+ displayPortConflicts: () => import_prompts.displayPortConflicts,
31
+ displayPrerequisites: () => import_prompts.displayPrerequisites,
32
+ displayWelcome: () => import_prompts.displayWelcome,
33
+ envFileExists: () => import_env.envFileExists,
34
+ generateSecret: () => import_env.generateSecret,
35
+ getConflictingPorts: () => import_ports.getConflictingPorts,
36
+ hasPortConflicts: () => import_ports.hasPortConflicts,
37
+ hasRequiredPrerequisites: () => import_prerequisites.hasRequiredPrerequisites,
38
+ markOnboarded: () => import_files.markOnboarded,
39
+ promptPassword: () => import_prompts.promptPassword,
40
+ promptSelect: () => import_prompts.promptSelect,
41
+ promptText: () => import_prompts.promptText,
42
+ readEnvVariable: () => import_env.readEnvVariable,
43
+ showError: () => import_prompts.showError,
44
+ showInfo: () => import_prompts.showInfo,
45
+ showSpinner: () => import_prompts.showSpinner,
46
+ showStep: () => import_prompts.showStep,
47
+ showSuccess: () => import_prompts.showSuccess,
48
+ showWarning: () => import_prompts.showWarning,
49
+ updateAppConfig: () => import_files.updateAppConfig,
50
+ updateEnvVariable: () => import_env.updateEnvVariable,
51
+ updatePackageJson: () => import_files.updatePackageJson
52
+ });
53
+ module.exports = __toCommonJS(index_exports);
54
+ var import_prerequisites = require("./utils/prerequisites"), import_ports = require("./utils/ports"), import_env = require("./utils/env"), import_files = require("./utils/files"), import_prompts = require("./utils/prompts");
55
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1,6 @@
1
+ {
2
+ "version": 3,
3
+ "sources": ["../../src/index.ts"],
4
+ "mappings": ";;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAUA,2BAOO,kCAGP,eAMO,0BAGP,aAOO,wBAGP,eAKO,0BAGP,iBAeO;",
5
+ "names": []
6
+ }
@@ -0,0 +1,94 @@
1
+ "use strict";
2
+ var __defProp = Object.defineProperty;
3
+ var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
4
+ var __getOwnPropNames = Object.getOwnPropertyNames;
5
+ var __hasOwnProp = Object.prototype.hasOwnProperty;
6
+ var __export = (target, all) => {
7
+ for (var name in all)
8
+ __defProp(target, name, { get: all[name], enumerable: !0 });
9
+ }, __copyProps = (to, from, except, desc) => {
10
+ if (from && typeof from == "object" || typeof from == "function")
11
+ for (let key of __getOwnPropNames(from))
12
+ !__hasOwnProp.call(to, key) && key !== except && __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
13
+ return to;
14
+ };
15
+ var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: !0 }), mod);
16
+ var index_exports = {};
17
+ __export(index_exports, {
18
+ TAKEOUT_PORTS: () => import_ports.TAKEOUT_PORTS,
19
+ checkAllPorts: () => import_ports.checkAllPorts,
20
+ checkAllPrerequisites: () => import_prerequisites.checkAllPrerequisites,
21
+ checkBun: () => import_prerequisites.checkBun,
22
+ checkDocker: () => import_prerequisites.checkDocker,
23
+ checkGit: () => import_prerequisites.checkGit,
24
+ checkNode: () => import_prerequisites.checkNode,
25
+ checkOnboarded: () => import_files.checkOnboarded,
26
+ checkPort: () => import_ports.checkPort,
27
+ confirmContinue: () => import_prompts.confirmContinue,
28
+ copyEnvFile: () => import_env.copyEnvFile,
29
+ createEnvLocal: () => import_env.createEnvLocal,
30
+ displayOutro: () => import_prompts.displayOutro,
31
+ displayPortConflicts: () => import_prompts.displayPortConflicts,
32
+ displayPrerequisites: () => import_prompts.displayPrerequisites,
33
+ displayWelcome: () => import_prompts.displayWelcome,
34
+ envFileExists: () => import_env.envFileExists,
35
+ generateSecret: () => import_env.generateSecret,
36
+ getConflictingPorts: () => import_ports.getConflictingPorts,
37
+ hasPortConflicts: () => import_ports.hasPortConflicts,
38
+ hasRequiredPrerequisites: () => import_prerequisites.hasRequiredPrerequisites,
39
+ markOnboarded: () => import_files.markOnboarded,
40
+ promptPassword: () => import_prompts.promptPassword,
41
+ promptSelect: () => import_prompts.promptSelect,
42
+ promptText: () => import_prompts.promptText,
43
+ readEnvVariable: () => import_env.readEnvVariable,
44
+ showError: () => import_prompts.showError,
45
+ showInfo: () => import_prompts.showInfo,
46
+ showSpinner: () => import_prompts.showSpinner,
47
+ showStep: () => import_prompts.showStep,
48
+ showSuccess: () => import_prompts.showSuccess,
49
+ showWarning: () => import_prompts.showWarning,
50
+ updateAppConfig: () => import_files.updateAppConfig,
51
+ updateEnvVariable: () => import_env.updateEnvVariable,
52
+ updatePackageJson: () => import_files.updatePackageJson
53
+ });
54
+ module.exports = __toCommonJS(index_exports);
55
+ var import_prerequisites = require("./utils/prerequisites"), import_ports = require("./utils/ports"), import_env = require("./utils/env"), import_files = require("./utils/files"), import_prompts = require("./utils/prompts");
56
+ // Annotate the CommonJS export names for ESM import in node:
57
+ 0 && (module.exports = {
58
+ TAKEOUT_PORTS,
59
+ checkAllPorts,
60
+ checkAllPrerequisites,
61
+ checkBun,
62
+ checkDocker,
63
+ checkGit,
64
+ checkNode,
65
+ checkOnboarded,
66
+ checkPort,
67
+ confirmContinue,
68
+ copyEnvFile,
69
+ createEnvLocal,
70
+ displayOutro,
71
+ displayPortConflicts,
72
+ displayPrerequisites,
73
+ displayWelcome,
74
+ envFileExists,
75
+ generateSecret,
76
+ getConflictingPorts,
77
+ hasPortConflicts,
78
+ hasRequiredPrerequisites,
79
+ markOnboarded,
80
+ promptPassword,
81
+ promptSelect,
82
+ promptText,
83
+ readEnvVariable,
84
+ showError,
85
+ showInfo,
86
+ showSpinner,
87
+ showStep,
88
+ showSuccess,
89
+ showWarning,
90
+ updateAppConfig,
91
+ updateEnvVariable,
92
+ updatePackageJson
93
+ });
94
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1,6 @@
1
+ {
2
+ "version": 3,
3
+ "sources": ["../../src/index.ts"],
4
+ "mappings": ";;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAMA,2BAA4G,kCAE5G,eAA+F,0BAE/F,aAA+G,wBAE/G,eAAkF,0BAElF,iBAA0N;",
5
+ "names": []
6
+ }
@@ -0,0 +1,16 @@
1
+ var __defProp = Object.defineProperty;
2
+ var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
3
+ var __getOwnPropNames = Object.getOwnPropertyNames;
4
+ var __hasOwnProp = Object.prototype.hasOwnProperty;
5
+ var __copyProps = (to, from, except, desc) => {
6
+ if (from && typeof from == "object" || typeof from == "function") for (let key of __getOwnPropNames(from)) !__hasOwnProp.call(to, key) && key !== except && __defProp(to, key, {
7
+ get: () => from[key],
8
+ enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable
9
+ });
10
+ return to;
11
+ };
12
+ var __toCommonJS = mod => __copyProps(__defProp({}, "__esModule", {
13
+ value: !0
14
+ }), mod);
15
+ var types_exports = {};
16
+ module.exports = __toCommonJS(types_exports);
@@ -0,0 +1,14 @@
1
+ var __defProp = Object.defineProperty;
2
+ var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
3
+ var __getOwnPropNames = Object.getOwnPropertyNames;
4
+ var __hasOwnProp = Object.prototype.hasOwnProperty;
5
+ var __copyProps = (to, from, except, desc) => {
6
+ if (from && typeof from == "object" || typeof from == "function")
7
+ for (let key of __getOwnPropNames(from))
8
+ !__hasOwnProp.call(to, key) && key !== except && __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
9
+ return to;
10
+ };
11
+ var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: !0 }), mod);
12
+ var types_exports = {};
13
+ module.exports = __toCommonJS(types_exports);
14
+ //# sourceMappingURL=types.js.map
@@ -0,0 +1,6 @@
1
+ {
2
+ "version": 3,
3
+ "sources": ["../../src/types.ts"],
4
+ "mappings": ";;;;;;;;;;;AAAA;AAAA;",
5
+ "names": []
6
+ }
@@ -0,0 +1,15 @@
1
+ "use strict";
2
+ var __defProp = Object.defineProperty;
3
+ var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
4
+ var __getOwnPropNames = Object.getOwnPropertyNames;
5
+ var __hasOwnProp = Object.prototype.hasOwnProperty;
6
+ var __copyProps = (to, from, except, desc) => {
7
+ if (from && typeof from == "object" || typeof from == "function")
8
+ for (let key of __getOwnPropNames(from))
9
+ !__hasOwnProp.call(to, key) && key !== except && __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
10
+ return to;
11
+ };
12
+ var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: !0 }), mod);
13
+ var types_exports = {};
14
+ module.exports = __toCommonJS(types_exports);
15
+ //# sourceMappingURL=types.js.map
@@ -0,0 +1,6 @@
1
+ {
2
+ "version": 3,
3
+ "sources": ["../../src/types.ts"],
4
+ "mappings": ";;;;;;;;;;;;AAAA;AAAA;",
5
+ "names": []
6
+ }
@@ -0,0 +1,272 @@
1
+ var __create = Object.create;
2
+ var __defProp = Object.defineProperty;
3
+ var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
4
+ var __getOwnPropNames = Object.getOwnPropertyNames;
5
+ var __getProtoOf = Object.getPrototypeOf,
6
+ __hasOwnProp = Object.prototype.hasOwnProperty;
7
+ var __export = (target, all) => {
8
+ for (var name in all) __defProp(target, name, {
9
+ get: all[name],
10
+ enumerable: !0
11
+ });
12
+ },
13
+ __copyProps = (to, from, except, desc) => {
14
+ if (from && typeof from == "object" || typeof from == "function") for (let key of __getOwnPropNames(from)) !__hasOwnProp.call(to, key) && key !== except && __defProp(to, key, {
15
+ get: () => from[key],
16
+ enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable
17
+ });
18
+ return to;
19
+ };
20
+ var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
21
+ // If the importer is in node compatibility mode or this is not an ESM
22
+ // file that has been converted to a CommonJS file using a Babel-
23
+ // compatible transform (i.e. "__esModule" has not been set), then set
24
+ // "default" to the CommonJS "module.exports" for node compatibility.
25
+ isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", {
26
+ value: mod,
27
+ enumerable: !0
28
+ }) : target, mod)),
29
+ __toCommonJS = mod => __copyProps(__defProp({}, "__esModule", {
30
+ value: !0
31
+ }), mod);
32
+ var env_categories_exports = {};
33
+ __export(env_categories_exports, {
34
+ envCategories: () => envCategories,
35
+ getAllVariables: () => getAllVariables,
36
+ getCategoryById: () => getCategoryById,
37
+ getOptionalCategories: () => getOptionalCategories,
38
+ getRequiredCategories: () => getRequiredCategories,
39
+ getVariableByKey: () => getVariableByKey
40
+ });
41
+ module.exports = __toCommonJS(env_categories_exports);
42
+ var import_picocolors = __toESM(require("picocolors"), 1);
43
+ const envCategories = [{
44
+ id: "core",
45
+ name: "Core Configuration",
46
+ description: "Essential configuration for your production deployment",
47
+ required: !0,
48
+ variables: [{
49
+ key: "BETTER_AUTH_SECRET",
50
+ label: "Authentication Secret",
51
+ description: "Secret key for session encryption and JWT signing",
52
+ instructions: `Generate a secure random key:
53
+ ${import_picocolors.default.cyan("openssl rand -hex 32")}`,
54
+ required: !0,
55
+ type: "secret",
56
+ generator: () => require("node:crypto").randomBytes(32).toString("hex")
57
+ }, {
58
+ key: "BETTER_AUTH_URL",
59
+ label: "Authentication URL",
60
+ description: "The public URL where your app will be hosted",
61
+ instructions: "Enter your production domain (e.g., https://your-app.com)",
62
+ required: !0,
63
+ type: "text",
64
+ placeholder: "https://your-app.com"
65
+ }, {
66
+ key: "ONE_SERVER_URL",
67
+ label: "Server URL",
68
+ description: "The URL for your main server",
69
+ instructions: "Usually the same as your authentication URL",
70
+ required: !0,
71
+ type: "text",
72
+ placeholder: "https://your-app.com"
73
+ }, {
74
+ key: "VITE_PUBLIC_ZERO_SERVER",
75
+ label: "Zero Sync Server URL",
76
+ description: "WebSocket server for real-time sync",
77
+ instructions: "Typically a subdomain like https://zero.your-app.com",
78
+ required: !0,
79
+ type: "text",
80
+ placeholder: "https://zero.your-app.com"
81
+ }]
82
+ }, {
83
+ id: "database",
84
+ name: "Database (PostgreSQL)",
85
+ description: "Production database configuration - set by deployment platform (SST/uncloud)",
86
+ required: !1,
87
+ variables: [
88
+ // Note: ZERO_UPSTREAM_DB, ZERO_CVR_DB, and ZERO_CHANGE_DB are set dynamically
89
+ // by the deployment platform (SST or uncloud) and should NOT be configured here
90
+ ]
91
+ }, {
92
+ id: "storage",
93
+ name: "File Storage (S3/R2)",
94
+ description: "Object storage for user uploads and media files",
95
+ required: !1,
96
+ variables: [{
97
+ key: "CLOUDFLARE_R2_ENDPOINT",
98
+ label: "Storage Endpoint",
99
+ description: "S3-compatible storage endpoint",
100
+ instructions: `Options:
101
+ ${import_picocolors.default.cyan("Cloudflare R2")}: https://[account-id].r2.cloudflarestorage.com
102
+ ${import_picocolors.default.cyan("AWS S3")}: https://s3.[region].amazonaws.com
103
+ ${import_picocolors.default.cyan("DigitalOcean Spaces")}: https://[region].digitaloceanspaces.com`,
104
+ required: !1,
105
+ type: "text",
106
+ placeholder: "https://account-id.r2.cloudflarestorage.com"
107
+ }, {
108
+ key: "CLOUDFLARE_R2_ACCESS_KEY",
109
+ label: "Storage Access Key",
110
+ description: "Access key ID for your storage service",
111
+ instructions: "Get this from your storage provider dashboard",
112
+ required: !1,
113
+ type: "text"
114
+ }, {
115
+ key: "CLOUDFLARE_R2_SECRET_KEY",
116
+ label: "Storage Secret Key",
117
+ description: "Secret access key for your storage service",
118
+ instructions: "Keep this secure - it provides full access to your storage",
119
+ required: !1,
120
+ type: "secret"
121
+ }, {
122
+ key: "CLOUDFLARE_R2_PUBLIC_URL",
123
+ label: "Public Storage URL",
124
+ description: "Public URL for serving stored files",
125
+ instructions: "Usually a CDN URL or custom domain pointing to your bucket",
126
+ required: !1,
127
+ type: "text",
128
+ placeholder: "https://cdn.your-app.com"
129
+ }]
130
+ }, {
131
+ id: "apple",
132
+ name: "Apple App Store",
133
+ description: "Configuration for iOS app and push notifications",
134
+ required: !1,
135
+ variables: [{
136
+ key: "APNS_TEAM_ID",
137
+ label: "Apple Team ID",
138
+ description: "Your Apple Developer Team ID",
139
+ instructions: `Find in Apple Developer Portal:
140
+ 1. Go to ${import_picocolors.default.cyan("https://developer.apple.com/account")}
141
+ 2. Look for "Team ID" in Membership Details`,
142
+ required: !1,
143
+ type: "text",
144
+ placeholder: "XXXXXXXXXX"
145
+ }, {
146
+ key: "APNS_KEY_ID",
147
+ label: "APNs Key ID",
148
+ description: "Push notification authentication key ID",
149
+ instructions: `Create in Apple Developer Portal:
150
+ 1. Go to Certificates, Identifiers & Profiles
151
+ 2. Keys \u2192 Create a Key
152
+ 3. Check "Apple Push Notifications service (APNs)"
153
+ 4. Download the .p8 file and note the Key ID`,
154
+ required: !1,
155
+ type: "text",
156
+ placeholder: "XXXXXXXXXX"
157
+ }, {
158
+ key: "APNS_KEY",
159
+ label: "APNs Key Content",
160
+ description: "Contents of your APNs .p8 key file",
161
+ instructions: "Paste the entire contents of the .p8 file you downloaded",
162
+ required: !1,
163
+ type: "multiline"
164
+ }, {
165
+ key: "APNS_ENDPOINT",
166
+ label: "APNs Endpoint",
167
+ description: "Apple Push Notification service endpoint",
168
+ instructions: `Production: ${import_picocolors.default.green("https://api.push.apple.com")}
169
+ Sandbox: ${import_picocolors.default.yellow("https://api.sandbox.push.apple.com")}`,
170
+ required: !1,
171
+ type: "text",
172
+ default: "https://api.push.apple.com"
173
+ }]
174
+ }, {
175
+ id: "email",
176
+ name: "Email Service",
177
+ description: "Transactional email configuration",
178
+ required: !1,
179
+ variables: [{
180
+ key: "POSTMARK_SERVER_TOKEN",
181
+ label: "Postmark Server Token",
182
+ description: "API token for sending emails via Postmark",
183
+ instructions: `Get your token:
184
+ 1. Sign up at ${import_picocolors.default.cyan("https://postmarkapp.com")}
185
+ 2. Create a Server
186
+ 3. Go to Servers \u2192 API Tokens
187
+ 4. Copy your Server API Token
188
+
189
+ ${import_picocolors.default.yellow("Note: Free tier includes 100 emails/month")}`,
190
+ required: !1,
191
+ type: "text"
192
+ }]
193
+ }, {
194
+ id: "github",
195
+ name: "GitHub OAuth",
196
+ description: "Enable GitHub sign-in for your app",
197
+ required: !1,
198
+ variables: [{
199
+ key: "ONECHAT_GITHUB_CLIENT_ID",
200
+ label: "GitHub OAuth Client ID",
201
+ description: "Client ID for GitHub OAuth application",
202
+ instructions: `Create GitHub OAuth App:
203
+ 1. Go to ${import_picocolors.default.cyan("https://github.com/settings/developers")}
204
+ 2. New OAuth App
205
+ 3. Set Authorization callback URL:
206
+ ${import_picocolors.default.green("https://your-app.com/api/auth/callback/github")}
207
+ 4. Copy the Client ID`,
208
+ required: !1,
209
+ type: "text"
210
+ }, {
211
+ key: "ONECHAT_GITHUB_CLIENT_SECRET",
212
+ label: "GitHub OAuth Client Secret",
213
+ description: "Client secret for GitHub OAuth application",
214
+ instructions: "Copy the Client Secret from your GitHub OAuth App settings",
215
+ required: !1,
216
+ type: "secret"
217
+ }]
218
+ }, {
219
+ id: "aws",
220
+ name: "AWS Deployment",
221
+ description: "AWS credentials for SST deployment",
222
+ required: !1,
223
+ setupTime: "~30 minutes",
224
+ variables: [{
225
+ key: "AWS_ACCESS_KEY_ID",
226
+ label: "AWS Access Key ID",
227
+ description: "Access key for AWS deployment",
228
+ instructions: `${import_picocolors.default.yellow("\u26A0\uFE0F Setting up AWS takes about 30 minutes")}
229
+
230
+ Follow the SST guide for AWS setup:
231
+ ${import_picocolors.default.cyan("https://sst.dev/docs/aws-accounts/")}
232
+
233
+ Quick steps:
234
+ 1. Create AWS account or use existing
235
+ 2. Create IAM user with AdministratorAccess
236
+ 3. Generate access keys
237
+ 4. Copy Access Key ID`,
238
+ required: !1,
239
+ type: "text"
240
+ }, {
241
+ key: "AWS_SECRET_ACCESS_KEY",
242
+ label: "AWS Secret Access Key",
243
+ description: "Secret key for AWS deployment",
244
+ instructions: "Copy the Secret Access Key from IAM user creation",
245
+ required: !1,
246
+ type: "secret"
247
+ }, {
248
+ key: "AWS_REGION",
249
+ label: "AWS Region",
250
+ description: "AWS region for deployment",
251
+ instructions: "Choose a region close to your users (e.g., us-west-1, us-east-1, eu-west-1)",
252
+ required: !1,
253
+ type: "text",
254
+ default: "us-west-1",
255
+ placeholder: "us-west-1"
256
+ }]
257
+ }];
258
+ function getCategoryById(id) {
259
+ return envCategories.find(cat => cat.id === id);
260
+ }
261
+ function getRequiredCategories() {
262
+ return envCategories.filter(cat => cat.required);
263
+ }
264
+ function getOptionalCategories() {
265
+ return envCategories.filter(cat => !cat.required);
266
+ }
267
+ function getAllVariables() {
268
+ return envCategories.flatMap(cat => cat.variables);
269
+ }
270
+ function getVariableByKey(key) {
271
+ return getAllVariables().find(v => v.key === key);
272
+ }