lucy-cli 2.0.0-alpha.7 → 2.0.0-beta.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 (452) hide show
  1. package/.yarnrc.yml +0 -1
  2. package/dist/args.d.ts +1 -6
  3. package/dist/args.js +62 -7
  4. package/dist/args.js.map +1 -0
  5. package/dist/commands/checks.d.ts +7 -0
  6. package/dist/commands/checks.js +47 -0
  7. package/dist/commands/checks.js.map +1 -0
  8. package/dist/commands/cleanup.d.ts +4 -0
  9. package/dist/commands/cleanup.js +10 -0
  10. package/dist/commands/cleanup.js.map +1 -0
  11. package/dist/commands/copy.d.ts +6 -0
  12. package/dist/commands/copy.js +20 -0
  13. package/dist/commands/copy.js.map +1 -0
  14. package/dist/commands/edit.d.ts +10 -0
  15. package/dist/commands/edit.js +67 -0
  16. package/dist/commands/edit.js.map +1 -0
  17. package/dist/commands/exec.d.ts +7 -0
  18. package/dist/commands/exec.js +67 -0
  19. package/dist/commands/exec.js.map +1 -0
  20. package/dist/commands/git.d.ts +8 -0
  21. package/dist/commands/git.js +104 -0
  22. package/dist/commands/git.js.map +1 -0
  23. package/dist/commands/home.d.ts +4 -0
  24. package/dist/commands/home.js +18 -0
  25. package/dist/commands/home.js.map +1 -0
  26. package/dist/commands/install.d.ts +8 -0
  27. package/dist/commands/install.js +165 -0
  28. package/dist/commands/install.js.map +1 -0
  29. package/dist/commands/read.d.ts +6 -0
  30. package/dist/commands/read.js +40 -0
  31. package/dist/commands/read.js.map +1 -0
  32. package/dist/commands/write.d.ts +7 -0
  33. package/dist/commands/write.js +28 -0
  34. package/dist/commands/write.js.map +1 -0
  35. package/dist/commands.js +1 -0
  36. package/dist/commands.js.map +1 -0
  37. package/dist/config.d.ts +29 -7
  38. package/dist/config.js +90 -26
  39. package/dist/config.js.map +1 -0
  40. package/dist/error.d.ts +1 -9
  41. package/dist/error.js +1 -2
  42. package/dist/error.js.map +1 -0
  43. package/dist/helpers.d.ts +9 -0
  44. package/dist/helpers.js +83 -0
  45. package/dist/helpers.js.map +1 -0
  46. package/dist/index.d.ts +1 -0
  47. package/dist/index.js +77 -9
  48. package/dist/index.js.map +1 -0
  49. package/dist/init/blocks.d.ts +5 -0
  50. package/dist/init/blocks.js +62 -0
  51. package/dist/init/blocks.js.map +1 -0
  52. package/dist/init/cargo.d.ts +2 -0
  53. package/dist/init/cargo.js +21 -0
  54. package/dist/init/cargo.js.map +1 -0
  55. package/dist/init/expo.d.ts +5 -0
  56. package/dist/init/expo.js +52 -0
  57. package/dist/init/expo.js.map +1 -0
  58. package/dist/init/gitModules.d.ts +2 -0
  59. package/dist/init/gitModules.js +13 -0
  60. package/dist/init/gitModules.js.map +1 -0
  61. package/dist/init/index.d.ts +4 -0
  62. package/dist/init/index.js +77 -0
  63. package/dist/init/index.js.map +1 -0
  64. package/dist/init/monorepo.d.ts +4 -0
  65. package/dist/init/monorepo.js +48 -0
  66. package/dist/init/monorepo.js.map +1 -0
  67. package/dist/init/prepareVelo.d.ts +2 -0
  68. package/dist/init/prepareVelo.js +16 -0
  69. package/dist/init/prepareVelo.js.map +1 -0
  70. package/dist/init/tauri.d.ts +5 -0
  71. package/dist/init/tauri.js +32 -0
  72. package/dist/init/tauri.js.map +1 -0
  73. package/dist/init/templates.d.ts +5 -0
  74. package/dist/init/templates.js +93 -0
  75. package/dist/init/templates.js.map +1 -0
  76. package/dist/init/velo.d.ts +5 -0
  77. package/dist/init/velo.js +60 -0
  78. package/dist/init/velo.js.map +1 -0
  79. package/dist/policy.js +1 -0
  80. package/dist/policy.js.map +1 -0
  81. package/dist/prepare.js +1 -0
  82. package/dist/prepare.js.map +1 -0
  83. package/dist/runtime.d.ts +1 -1
  84. package/dist/runtime.js +1 -0
  85. package/dist/runtime.js.map +1 -0
  86. package/dist/schemas/gulp.d.ts +25 -0
  87. package/dist/schemas/gulp.js +8 -0
  88. package/dist/schemas/gulp.js.map +1 -0
  89. package/dist/schemas/index.d.ts +10 -0
  90. package/dist/schemas/index.js +9 -0
  91. package/dist/schemas/index.js.map +1 -0
  92. package/dist/schemas/lucy.d.ts +29 -0
  93. package/dist/schemas/lucy.js +42 -0
  94. package/dist/schemas/lucy.js.map +1 -0
  95. package/dist/schemas/tsconfig.js +2 -0
  96. package/dist/schemas/tsconfig.js.map +1 -0
  97. package/dist/schemas/types.d.ts +33 -0
  98. package/dist/schemas/types.js +5 -1
  99. package/dist/schemas/types.js.map +1 -0
  100. package/dist/states.js +1 -0
  101. package/dist/states.js.map +1 -0
  102. package/dist/tasks/Gulpfile.d.ts +4 -0
  103. package/dist/tasks/Gulpfile.js +111 -0
  104. package/dist/tasks/Gulpfile.js.map +1 -0
  105. package/dist/tasks/gulp/backend.d.ts +4 -0
  106. package/dist/tasks/gulp/backend.js +92 -0
  107. package/dist/tasks/gulp/backend.js.map +1 -0
  108. package/dist/tasks/gulp/checks.d.ts +4 -0
  109. package/dist/tasks/gulp/checks.js +202 -0
  110. package/dist/tasks/gulp/checks.js.map +1 -0
  111. package/dist/tasks/gulp/clean.d.ts +3 -0
  112. package/dist/tasks/gulp/clean.js +33 -0
  113. package/dist/tasks/gulp/clean.js.map +1 -0
  114. package/dist/tasks/gulp/copy.d.ts +3 -0
  115. package/dist/tasks/gulp/copy.js +34 -0
  116. package/dist/tasks/gulp/copy.js.map +1 -0
  117. package/dist/tasks/gulp/helpers.d.ts +3 -0
  118. package/dist/tasks/gulp/helpers.js +19 -0
  119. package/dist/tasks/gulp/helpers.js.map +1 -0
  120. package/dist/tasks/gulp/pages.d.ts +2 -0
  121. package/dist/tasks/gulp/pages.js +39 -0
  122. package/dist/tasks/gulp/pages.js.map +1 -0
  123. package/dist/tasks/gulp/pipeline.d.ts +1 -0
  124. package/dist/tasks/gulp/pipeline.js +29 -0
  125. package/dist/tasks/gulp/pipeline.js.map +1 -0
  126. package/dist/tasks/gulp/public.d.ts +3 -0
  127. package/dist/tasks/gulp/public.js +50 -0
  128. package/dist/tasks/gulp/public.js.map +1 -0
  129. package/dist/tasks/gulp/styles.d.ts +3 -0
  130. package/dist/tasks/gulp/styles.js +40 -0
  131. package/dist/tasks/gulp/styles.js.map +1 -0
  132. package/dist/tasks/gulp/templates.d.ts +2 -0
  133. package/dist/tasks/gulp/templates.js +45 -0
  134. package/dist/tasks/gulp/templates.js.map +1 -0
  135. package/dist/tasks/gulp/types.d.ts +4 -0
  136. package/dist/tasks/gulp/types.js +293 -0
  137. package/dist/tasks/gulp/types.js.map +1 -0
  138. package/dist/tasks/gulp/watchers.d.ts +3 -0
  139. package/dist/tasks/gulp/watchers.js +59 -0
  140. package/dist/tasks/gulp/watchers.js.map +1 -0
  141. package/dist/tasks/index.d.ts +4 -0
  142. package/dist/tasks/index.js +23 -0
  143. package/dist/tasks/index.js.map +1 -0
  144. package/dist/tasks/syncSettings.d.ts +3 -0
  145. package/dist/tasks/syncSettings.js +18 -0
  146. package/dist/tasks/syncSettings.js.map +1 -0
  147. package/dist/utils/index.js +2 -0
  148. package/dist/utils/index.js.map +1 -0
  149. package/dist/utils/logger.d.ts +17 -0
  150. package/dist/utils/logger.js +37 -0
  151. package/dist/utils/logger.js.map +1 -0
  152. package/dist/wix-sdk/check.d.ts +4 -0
  153. package/dist/wix-sdk/check.js +23 -0
  154. package/dist/wix-sdk/check.js.map +1 -0
  155. package/dist/wix-sdk/client.d.ts +10 -0
  156. package/dist/wix-sdk/client.js +18 -0
  157. package/dist/wix-sdk/client.js.map +1 -0
  158. package/dist/wix-sdk/index.d.ts +4 -0
  159. package/dist/wix-sdk/index.js +15 -0
  160. package/dist/wix-sdk/index.js.map +1 -0
  161. package/dist/wix-sdk/init.d.ts +4 -0
  162. package/dist/wix-sdk/init.js +51 -0
  163. package/dist/wix-sdk/init.js.map +1 -0
  164. package/dist/wix-sdk/run.d.ts +4 -0
  165. package/dist/wix-sdk/run.js +53 -0
  166. package/dist/wix-sdk/run.js.map +1 -0
  167. package/dist/wix-sync/client.d.ts +3 -0
  168. package/dist/wix-sync/client.js +5 -0
  169. package/dist/wix-sync/client.js.map +1 -0
  170. package/dist/wix-sync/export.d.ts +4 -0
  171. package/dist/wix-sync/export.js +15 -0
  172. package/dist/wix-sync/export.js.map +1 -0
  173. package/dist/wix-sync/import.d.ts +4 -0
  174. package/dist/wix-sync/import.js +26 -0
  175. package/dist/wix-sync/import.js.map +1 -0
  176. package/dist/wix-sync/index.d.ts +4 -0
  177. package/dist/wix-sync/index.js +35 -0
  178. package/dist/wix-sync/index.js.map +1 -0
  179. package/dist/wix-sync/init.d.ts +4 -0
  180. package/dist/wix-sync/init.js +74 -0
  181. package/dist/wix-sync/init.js.map +1 -0
  182. package/dist/wix-sync/is-alive.d.ts +4 -0
  183. package/dist/wix-sync/is-alive.js +23 -0
  184. package/dist/wix-sync/is-alive.js.map +1 -0
  185. package/dist/wix-sync/migrate.d.ts +4 -0
  186. package/dist/wix-sync/migrate.js +21 -0
  187. package/dist/wix-sync/migrate.js.map +1 -0
  188. package/dist/wix-sync/sync.d.ts +4 -0
  189. package/dist/wix-sync/sync.js +26 -0
  190. package/dist/wix-sync/sync.js.map +1 -0
  191. package/files/sync-data/data/test.csv +17 -0
  192. package/files/sync-data/files/lucy.jpg +0 -0
  193. package/files/sync-data/schema/test.json +11 -0
  194. package/files/templates/block[D]/files/.stylelintrc.js +8 -0
  195. package/files/templates/block[D]/lucy.json +9 -0
  196. package/files/templates/cargo[D]/files/.env +1 -0
  197. package/files/templates/cargo[D]/files/Cargo.toml +238 -0
  198. package/files/templates/cargo[D]/files/Makefile.toml +4 -0
  199. package/files/templates/cargo[D]/files/build/main.rs +35 -0
  200. package/files/templates/cargo[D]/files/config/beta.json +19 -0
  201. package/files/templates/cargo[D]/files/config/ci.json +15 -0
  202. package/files/templates/cargo[D]/files/config/default.json +71 -0
  203. package/files/templates/cargo[D]/files/config/development.json +10 -0
  204. package/files/templates/cargo[D]/files/config/produktion.json +5 -0
  205. package/files/templates/cargo[D]/files/config/stage.json +4 -0
  206. package/files/templates/cargo[D]/files/locales/todo.yml +3 -0
  207. package/files/templates/cargo[D]/files/public/index.html +1 -0
  208. package/files/templates/cargo[D]/lucy.json +15 -0
  209. package/files/templates/expo[D]/files/.stylelintrc.js +8 -0
  210. package/files/{expo → templates/expo[D]/files}/eas.json +9 -3
  211. package/files/templates/expo[D]/files/lib/data.ts +197 -0
  212. package/files/{expo → templates/expo[D]/files}/metro.config.js +6 -1
  213. package/files/templates/expo[D]/files/pnpm-workspace.yaml +3 -0
  214. package/files/templates/expo[D]/lucy.json +86 -0
  215. package/files/templates/monorepo[D]/files/.editorconfig +10 -0
  216. package/files/templates/monorepo[D]/files/.nvmrc +1 -0
  217. package/files/templates/monorepo[D]/files/.prettierignore +23 -0
  218. package/files/templates/monorepo[D]/files/.prettierrc.json +15 -0
  219. package/files/templates/monorepo[D]/files/.stylelintrc.js +8 -0
  220. package/files/templates/monorepo[D]/files/.yarnrc +1 -0
  221. package/files/templates/monorepo[D]/files/.yarnrc.yml +3 -0
  222. package/files/templates/monorepo[D]/files/README.md +109 -0
  223. package/files/templates/monorepo[D]/files/currents.config.ts +5 -0
  224. package/files/templates/monorepo[D]/files/nx.json +25 -0
  225. package/files/templates/monorepo[D]/files/pnpm-workspace.yaml +11 -0
  226. package/files/templates/monorepo[D]/files/tsconfig.json +6 -0
  227. package/files/templates/monorepo[D]/files/typedoc.json +25 -0
  228. package/files/templates/monorepo[D]/files/vitest.config.ts +27 -0
  229. package/files/templates/monorepo[D]/lucy.json +69 -0
  230. package/files/templates/tauri[D]/lucy.json +9 -0
  231. package/files/templates/velo[D]/files/.prettierignore +23 -0
  232. package/files/templates/velo[D]/files/.prettierrc.js +16 -0
  233. package/files/templates/velo[D]/lucy.json +137 -0
  234. package/old/Gulpfile.d.ts +34 -0
  235. package/old/Gulpfile.js +116 -0
  236. package/old/Gulpfile.js.map +1 -0
  237. package/old/gulp/backend.d.ts +3 -0
  238. package/old/gulp/backend.js +92 -0
  239. package/old/gulp/backend.js.map +1 -0
  240. package/old/gulp/checks.d.ts +3 -0
  241. package/old/gulp/checks.js +205 -0
  242. package/old/gulp/checks.js.map +1 -0
  243. package/old/gulp/clean.d.ts +3 -0
  244. package/old/gulp/clean.js +29 -0
  245. package/old/gulp/clean.js.map +1 -0
  246. package/old/gulp/copy.d.ts +2 -0
  247. package/old/gulp/copy.js +34 -0
  248. package/old/gulp/copy.js.map +1 -0
  249. package/old/gulp/helpers.d.ts +2 -0
  250. package/old/gulp/helpers.js +25 -0
  251. package/old/gulp/helpers.js.map +1 -0
  252. package/old/gulp/pages.d.ts +2 -0
  253. package/old/gulp/pages.js +37 -0
  254. package/old/gulp/pages.js.map +1 -0
  255. package/old/gulp/pipeline.d.ts +1 -0
  256. package/old/gulp/pipeline.js +29 -0
  257. package/old/gulp/pipeline.js.map +1 -0
  258. package/old/gulp/public.d.ts +2 -0
  259. package/old/gulp/public.js +50 -0
  260. package/old/gulp/public.js.map +1 -0
  261. package/old/gulp/styles.d.ts +2 -0
  262. package/old/gulp/styles.js +40 -0
  263. package/old/gulp/styles.js.map +1 -0
  264. package/old/gulp/templates.d.ts +2 -0
  265. package/old/gulp/templates.js +33 -0
  266. package/old/gulp/templates.js.map +1 -0
  267. package/old/gulp/types.d.ts +4 -0
  268. package/old/gulp/types.js +289 -0
  269. package/old/gulp/types.js.map +1 -0
  270. package/old/gulp/watchers.d.ts +9 -0
  271. package/old/gulp/watchers.js +59 -0
  272. package/old/gulp/watchers.js.map +1 -0
  273. package/old/helpers.d.ts +32 -0
  274. package/old/helpers.js +267 -0
  275. package/old/helpers.js.map +1 -0
  276. package/{src copy/helpers.ts → old/helpers.ts} +1 -1
  277. package/old/index.d.ts +59 -0
  278. package/old/index.js +288 -0
  279. package/old/index.js.map +1 -0
  280. package/old/init.d.ts +8 -0
  281. package/old/init.js +165 -0
  282. package/old/init.js.map +1 -0
  283. package/old/models.d.ts +37 -0
  284. package/old/models.js +2 -0
  285. package/old/models.js.map +1 -0
  286. package/old/prepare.d.ts +8 -0
  287. package/old/prepare.js +20 -0
  288. package/old/prepare.js.map +1 -0
  289. package/old/schemas/index.js +2 -0
  290. package/old/schemas/index.js.map +1 -0
  291. package/old/schemas/index.ts +0 -0
  292. package/old/schemas/types.d.ts +0 -0
  293. package/old/schemas/types.js +2 -0
  294. package/old/schemas/types.js.map +1 -0
  295. package/old/schemas/types.ts +0 -0
  296. package/old/sync.d.ts +2 -0
  297. package/old/sync.js +88 -0
  298. package/old/sync.js.map +1 -0
  299. package/package.json +18 -19
  300. package/patches/velo-sync+0.0.9.patch +13 -0
  301. package/src/args.ts +62 -17
  302. package/src/commands/checks.ts +51 -0
  303. package/src/commands/cleanup.ts +11 -0
  304. package/src/commands/copy.ts +28 -0
  305. package/src/commands/edit.ts +81 -0
  306. package/src/commands/exec.ts +69 -0
  307. package/src/commands/git.ts +113 -0
  308. package/src/commands/home.ts +22 -0
  309. package/src/commands/install.ts +249 -0
  310. package/src/commands/read.ts +45 -0
  311. package/src/commands/write.ts +45 -0
  312. package/src/config.ts +116 -35
  313. package/src/error.ts +1 -2
  314. package/src/helpers.ts +92 -0
  315. package/src/index.ts +88 -13
  316. package/src/init/blocks.ts +85 -0
  317. package/src/init/cargo.ts +25 -0
  318. package/src/init/expo.ts +69 -0
  319. package/src/init/gitModules.ts +15 -0
  320. package/src/init/index.ts +81 -0
  321. package/src/init/monorepo.ts +72 -0
  322. package/src/init/prepareVelo.ts +19 -0
  323. package/src/init/tauri.ts +42 -0
  324. package/src/init/templates.ts +98 -0
  325. package/src/init/velo.ts +65 -0
  326. package/src/runtime.ts +1 -0
  327. package/src/schemas/gulp.ts +31 -0
  328. package/src/schemas/index.ts +13 -1
  329. package/src/schemas/lucy.ts +43 -0
  330. package/src/schemas/types.ts +40 -0
  331. package/src/tasks/Gulpfile.ts +207 -0
  332. package/src/tasks/gulp/backend.ts +113 -0
  333. package/src/tasks/gulp/checks.ts +218 -0
  334. package/src/tasks/gulp/clean.ts +38 -0
  335. package/src/tasks/gulp/copy.ts +38 -0
  336. package/src/tasks/gulp/helpers.ts +18 -0
  337. package/src/tasks/gulp/pages.ts +43 -0
  338. package/src/tasks/gulp/pipeline.ts +31 -0
  339. package/src/tasks/gulp/public.ts +61 -0
  340. package/src/tasks/gulp/styles.ts +47 -0
  341. package/src/tasks/gulp/templates.ts +53 -0
  342. package/src/tasks/gulp/types.ts +310 -0
  343. package/src/tasks/gulp/watchers.ts +97 -0
  344. package/src/tasks/index.ts +24 -0
  345. package/src/tasks/syncSettings.ts +21 -0
  346. package/src/types.d.ts +1 -1
  347. package/src/utils/index.ts +0 -0
  348. package/src/utils/logger.ts +40 -0
  349. package/src/wix-sdk/check.ts +24 -0
  350. package/src/wix-sdk/client.ts +18 -0
  351. package/src/wix-sdk/index.ts +17 -0
  352. package/src/wix-sdk/init.ts +54 -0
  353. package/src/wix-sdk/run.ts +56 -0
  354. package/src/wix-sync/client.ts +6 -0
  355. package/src/wix-sync/export.ts +19 -0
  356. package/src/wix-sync/import.ts +27 -0
  357. package/src/wix-sync/index.ts +36 -0
  358. package/src/wix-sync/init.ts +77 -0
  359. package/src/wix-sync/is-alive.ts +25 -0
  360. package/src/wix-sync/migrate.ts +23 -0
  361. package/src/wix-sync/sync.ts +27 -0
  362. package/tsconfig.json +6 -5
  363. package/dist/init.d.ts +0 -4
  364. package/dist/init.js +0 -275
  365. package/dist/models.js +0 -1
  366. package/dist/params.d.ts +0 -7
  367. package/dist/params.js +0 -23
  368. package/files/expo/.env +0 -1
  369. package/files/expo/lib/data.ts +0 -48
  370. package/files/expo/lucy.json +0 -8
  371. package/src/init.ts +0 -392
  372. /package/dist/{models.d.ts → schemas/tsconfig.d.ts} +0 -0
  373. /package/{files/expo/components/.gitkeep → dist/utils/index.d.ts} +0 -0
  374. /package/files/{expo → templates/expo[D]/files}/.nvmrc +0 -0
  375. /package/files/{expo → templates/expo[D]/files}/.prettierignore +0 -0
  376. /package/files/{expo → templates/expo[D]/files}/.prettierrc.js +0 -0
  377. /package/files/{expo → templates/expo[D]/files}/.yarnrc +0 -0
  378. /package/files/{expo → templates/expo[D]/files}/.yarnrc.yml +0 -0
  379. /package/files/{expo → templates/expo[D]/files}/README.md +0 -0
  380. /package/files/{expo → templates/expo[D]/files}/assets/fonts/SpaceMono-Regular.ttf +0 -0
  381. /package/files/{expo → templates/expo[D]/files}/assets/images/adaptive-icon.png +0 -0
  382. /package/files/{expo → templates/expo[D]/files}/assets/images/favicon.png +0 -0
  383. /package/files/{expo → templates/expo[D]/files}/assets/images/icon.png +0 -0
  384. /package/files/{expo → templates/expo[D]/files}/assets/images/splash-icon.png +0 -0
  385. /package/files/{expo → templates/expo[D]/files}/babel.config.js +0 -0
  386. /package/files/{expo/components/ui → templates/expo[D]/files/components}/.gitkeep +0 -0
  387. /package/files/{velo/typescript/__mocks__ → templates/expo[D]/files/components/ui}/.gitkeep +0 -0
  388. /package/files/{expo → templates/expo[D]/files}/constants/theme.ts +0 -0
  389. /package/files/{expo → templates/expo[D]/files}/eslint.config.mjs +0 -0
  390. /package/files/{expo → templates/expo[D]/files}/global.css +0 -0
  391. /package/files/{expo → templates/expo[D]/files}/hooks/useColorScheme.ts +0 -0
  392. /package/files/{expo → templates/expo[D]/files}/index.ts +0 -0
  393. /package/files/{expo → templates/expo[D]/files}/lib/utils/index.ts +0 -0
  394. /package/files/{expo → templates/expo[D]/files}/lib/utils/polyfills.ts +0 -0
  395. /package/files/{expo → templates/expo[D]/files}/lib/wix/client.ts +0 -0
  396. /package/files/{expo → templates/expo[D]/files}/lib/wix/error.ts +0 -0
  397. /package/files/{expo → templates/expo[D]/files}/lib/wix/index.ts +0 -0
  398. /package/files/{expo → templates/expo[D]/files}/nativewind-env.d.ts +0 -0
  399. /package/files/{expo → templates/expo[D]/files}/scripts/reset-project.ts +0 -0
  400. /package/files/{expo → templates/expo[D]/files}/tailwind.config.js +0 -0
  401. /package/files/{expo → templates/expo[D]/files}/tsconfig.json +0 -0
  402. /package/files/{expo → templates/expo[D]/files}/types/reset.d.ts +0 -0
  403. /package/files/{velo → templates/velo[D]/files}/.gitmodules +0 -0
  404. /package/files/{velo → templates/velo[D]/files}/.madgerc +0 -0
  405. /package/files/{velo → templates/velo[D]/files}/.nvmrc +0 -0
  406. /package/files/{velo → templates/velo[D]/files}/.stylelintrc.js +0 -0
  407. /package/files/{velo → templates/velo[D]/files}/.yarnrc.yml +0 -0
  408. /package/files/{velo → templates/velo[D]/files}/currents.config.js +0 -0
  409. /package/files/{velo → templates/velo[D]/files}/cypress/e2e/base/base.cy.ts +0 -0
  410. /package/files/{velo → templates/velo[D]/files}/cypress/fixtures/example.json +0 -0
  411. /package/files/{velo → templates/velo[D]/files}/cypress/support/commands.ts +0 -0
  412. /package/files/{velo → templates/velo[D]/files}/cypress/support/e2e.ts +0 -0
  413. /package/files/{velo → templates/velo[D]/files}/cypress/tsconfig.json +0 -0
  414. /package/files/{velo → templates/velo[D]/files}/cypress.config.mjs +0 -0
  415. /package/files/{velo → templates/velo[D]/files}/eslint.config.mjs +0 -0
  416. /package/files/{velo → templates/velo[D]/files}/local.tsconfig.json +0 -0
  417. /package/files/{velo → templates/velo[D]/files}/typedoc.json +0 -0
  418. /package/files/{velo/typescript/pages → templates/velo[D]/files/typescript/__mocks__}/.gitkeep +0 -0
  419. /package/files/{velo → templates/velo[D]/files}/typescript/backend/data.ts +0 -0
  420. /package/files/{velo → templates/velo[D]/files}/typescript/backend/events.ts +0 -0
  421. /package/files/{velo → templates/velo[D]/files}/typescript/backend/http-functions.ts +0 -0
  422. /package/files/{velo → templates/velo[D]/files}/typescript/backend/lib/http-functions/sync.ts +0 -0
  423. /package/files/{velo → templates/velo[D]/files}/typescript/backend/permissions.json +0 -0
  424. /package/files/{velo/typescript/public → templates/velo[D]/files/typescript/pages}/.gitkeep +0 -0
  425. /package/files/{velo/typescript/styles → templates/velo[D]/files/typescript/public}/.gitkeep +0 -0
  426. /package/files/{velo → templates/velo[D]/files}/typescript/public/scss/app.scss +0 -0
  427. /package/files/{velo/typescript/styles/global.scss → templates/velo[D]/files/typescript/styles/.gitkeep} +0 -0
  428. /package/{src copy/schemas/index.ts → files/templates/velo[D]/files/typescript/styles/global.scss} +0 -0
  429. /package/files/{velo → templates/velo[D]/files}/typescript/tsconfig.json +0 -0
  430. /package/files/{velo → templates/velo[D]/files}/vitest.config.ts +0 -0
  431. /package/{src copy → old}/Gulpfile.ts +0 -0
  432. /package/{src copy → old}/gulp/backend.ts +0 -0
  433. /package/{src copy → old}/gulp/checks.ts +0 -0
  434. /package/{src copy → old}/gulp/clean.ts +0 -0
  435. /package/{src copy → old}/gulp/copy.ts +0 -0
  436. /package/{src copy → old}/gulp/helpers.ts +0 -0
  437. /package/{src copy → old}/gulp/pages.ts +0 -0
  438. /package/{src copy → old}/gulp/pipeline.ts +0 -0
  439. /package/{src copy → old}/gulp/public.ts +0 -0
  440. /package/{src copy → old}/gulp/styles.ts +0 -0
  441. /package/{src copy → old}/gulp/templates.ts +0 -0
  442. /package/{src copy → old}/gulp/types.ts +0 -0
  443. /package/{src copy → old}/gulp/watchers.ts +0 -0
  444. /package/{src copy → old}/index.ts +0 -0
  445. /package/{src copy → old}/init.ts +0 -0
  446. /package/{src copy → old}/models.ts +0 -0
  447. /package/{src copy → old}/prepare.ts +0 -0
  448. /package/{src copy/schemas/types.ts → old/schemas/index.d.ts} +0 -0
  449. /package/{src copy → old}/settings.json +0 -0
  450. /package/{src copy → old}/sync.ts +0 -0
  451. /package/{src copy → old}/types.d.ts +0 -0
  452. /package/src/{models.ts → schemas/tsconfig.ts} +0 -0
@@ -1,48 +0,0 @@
1
- import { Effect, Schedule, Schema } from 'effect';
2
-
3
- import { client, ClientError } from './wix';
4
-
5
- const dataSchema = Schema.Struct({
6
- source: Schema.String,
7
- content: Schema.String,
8
- _id: Schema.String,
9
- _owner: Schema.String,
10
- _createdDate: Schema.Any,
11
- _updatedDate: Schema.Any,
12
- });
13
-
14
- const COLLECTION_NAME = 'dailySpiritQuotes';
15
-
16
- export const getQuote = () => Effect.gen(function* () {
17
- const count = yield* Effect.retry(Effect.tryPromise({
18
- try: () => client.items.query(COLLECTION_NAME).count(),
19
- catch: (error) => {
20
- console.error('Error fetching quotes:', error);
21
- Effect.fail(new ClientError());
22
- }
23
- }), Schedule.fromDelays(50, 100, 200, 400, 800));
24
-
25
- if (count === 0) {
26
- return yield* Effect.fail(new Error('No quotes found in the collection.'));
27
- }
28
-
29
- const randomIndex = Math.floor(Math.random() * count);
30
-
31
- const data = yield* Effect.retry(Effect.tryPromise({
32
- try: () => client.items.query(COLLECTION_NAME).skip(randomIndex).limit(1).find(),
33
- catch: (error) => {
34
- console.error('Error fetching quotes:', error);
35
- Effect.fail(new ClientError());
36
- }
37
- }), Schedule.fromDelays(50, 100, 200, 400, 800));
38
-
39
- yield* Effect.logDebug(`Fetched ${JSON.stringify(data, null, 2)}`);
40
-
41
- const quote = yield* Schema.decodeUnknown(dataSchema)(data.items[0]);
42
-
43
- return { source: quote.source, content: quote.content };
44
- }).pipe(Effect.catchAll((error) => {
45
- console.error('Failed to fetch quote:', error);
46
-
47
- return Effect.succeed({ source: 'The Lord', content: 'The ways of the Lord are inscrutable.' });
48
- }));
@@ -1,8 +0,0 @@
1
- {
2
- "modules": {},
3
- "wixSettings": {},
4
- "initialized": true,
5
- "wixPackages": {},
6
- "devPackages": {},
7
- "scripts": {}
8
- }
package/src/init.ts DELETED
@@ -1,392 +0,0 @@
1
- // import chalk from 'chalk';
2
- // import { existsSync, mkdirSync, promises as fsPromises } from 'fs';
3
- // import fse from 'fs-extra';
4
- // import { join } from 'path';
5
- // import fs from 'fs/promises';
6
- // import path from 'path';
7
- // import os from 'os';
8
- // import enquirer from 'enquirer';
9
- // import { ModuleSettings, ProjectSettings, blue, green, orange, red } from './index.js';
10
- // import { createTemplateFolder, gitInit, installPackages } from './helpers.js';
11
-
12
- import { Effect, Schema } from "effect/index"
13
- import { Config } from "./config.js";
14
- import { Command, Terminal, FileSystem, Path } from "@effect/platform"
15
- import { config } from "yargs";
16
- import { JsonSchema } from "./schemas/index.js";
17
-
18
- // const { Select } = enquirer as any;
19
- // /**
20
- // * Init Lucy project
21
- // * @param {string} cwd Current working directory
22
- // * @param {string} packageRoot Package root directory
23
- // * @returns {void}
24
- // */
25
- // export async function init(moduleSettings: ModuleSettings, projectSettings: ProjectSettings) {
26
-
27
- // if(projectSettings.packageJSON && projectSettings.packageJSON.wixLucy?.initialized && !moduleSettings.args.includes('-f')) {
28
- // console.log((`💩 ${red.underline.bold("=> This project is already initialized =>")} ${orange(moduleSettings.targetFolder)}`));
29
- // return;
30
- // }
31
-
32
- // const templatesPath = join(os.homedir(), '.lucy-cli');
33
- // if (!existsSync(templatesPath)) {
34
- // console.log(chalk.yellow(`Templates folder not found at ${orange(templatesPath)}. Creating it with a default template...`));
35
- // await createTemplateFolder(moduleSettings);
36
- // }
37
-
38
- // const templateChoices = (await fs.readdir(templatesPath, { withFileTypes: true }))
39
- // .filter(dirent => dirent.isDirectory())
40
- // .map(dirent => dirent.name);
41
-
42
- // if (templateChoices.length === 0) {
43
- // console.log((`💩 ${red.underline.bold("=> No templates found in =>")} ${orange(templatesPath)}`));
44
- // return;
45
- // }
46
-
47
- // const prompt = new Select({
48
- // name: 'template',
49
- // message: 'Select a project template',
50
- // choices: templateChoices
51
- // });
52
-
53
- // const selectedTemplate = await prompt.run();
54
- // const templateDir = join(templatesPath, selectedTemplate);
55
- // const templateFilesDir = join(templateDir, 'files');
56
- // const templateSettingsPath = join(templateDir, 'settings.json');
57
-
58
- // if (!existsSync(templateSettingsPath)) {
59
- // console.log((`💩 ${red.underline.bold("=> Template is missing settings.json at =>")} ${orange(templateSettingsPath)}`));
60
- // return;
61
- // }
62
-
63
- // try {
64
- // const templateSettingsRaw = await fs.readFile(templateSettingsPath, 'utf8');
65
- // moduleSettings.settings = JSON.parse(templateSettingsRaw);
66
- // } catch (e) {
67
- // console.log((`💩 ${red.underline.bold("=> Error reading or parsing template settings =>")} ${orange(e)}`));
68
- // return;
69
- // }
70
-
71
- // await copyFolder(templateFilesDir, moduleSettings.targetFolder);
72
-
73
- // await editJson(moduleSettings.packageJsonPath, ['type', 'scripts'], ['module', moduleSettings.settings.scripts ]);
74
- // await stringReplace(join(moduleSettings.targetFolder, 'currents.config.js'), ['__ProjectName__'], [path.basename(moduleSettings.targetFolder)]);
75
-
76
- // await installPackages(moduleSettings.settings.wixPackages, moduleSettings.settings.devPackages, moduleSettings.targetFolder, moduleSettings.lockVersion);
77
-
78
- // await editJson(join(moduleSettings.targetFolder, 'jsconfig.json'), ['compilerOptions', 'exclude'], [moduleSettings.settings.wixSettings.compilerOptions, moduleSettings.settings.wixSettings.exclude]);
79
- // await editJson(join(moduleSettings.targetFolder, 'typedoc.json'), ['name'], [path.basename(moduleSettings.targetFolder)]);
80
-
81
- // await gitInit(moduleSettings.targetFolder, moduleSettings.settings.modules, moduleSettings.force);
82
-
83
- // moduleSettings.settings.initialized = true;
84
-
85
- // const eslintrcPath = join(moduleSettings.targetFolder, '.eslintrc.json');
86
- // if(existsSync(eslintrcPath)) {
87
- // console.log((`🐕 ${blue.underline.bold("=> Deleting .eslintrc.json")}`));
88
- // await fs.rm(join(eslintrcPath), { recursive: false }).catch(e => {
89
- // console.log((`💩 ${red.underline.bold("=> Could not delete .eslintrc.json ")} ${red.bold("=> ", e)}`));
90
- // });
91
- // }
92
-
93
- // console.log((`🐕 ${blue.underline.bold("=> Writing settings to lucy.json")}`));
94
- // await fs.writeFile(join(moduleSettings.targetFolder, 'lucy.json'), JSON.stringify(moduleSettings.settings, null, 2));
95
-
96
- // console.log(chalk.greenBright.underline('🐶 => Initialization done!'));
97
- // }
98
-
99
- // /**
100
- // * Copy files from source to target
101
- // * @param {string} source Source folder
102
- // * @param {string} target Target folder
103
- // * @returns {Promise<void>}
104
- // */
105
- // async function copyFolder(source: string, target: string): Promise<void> {
106
- // if (!existsSync(target)){
107
- // console.log((`💩 ${red.underline.bold("=> Target folder doesn't exist =>")} ${orange(target)}`));
108
- // return;
109
- // }
110
-
111
- // try {
112
- // const files = await fsPromises.readdir(source);
113
- // for (const file of files){
114
- // const sourcePath = join(source, file);
115
- // const targetPath = join(target, file);
116
-
117
- // if (file === 'lucy.json' && existsSync(targetPath)){
118
- // continue;
119
- // }
120
- // const stats = await fsPromises.stat(sourcePath);
121
- // if (stats.isDirectory()){
122
- // if (!existsSync(file)){
123
- // mkdirSync(file);
124
- // }
125
- // await fse.copySync(sourcePath, targetPath, { overwrite: true });
126
- // } else {
127
- // fse.copySync(sourcePath, targetPath, { overwrite: true });
128
- // }
129
- // }
130
- // } catch (err){
131
- // console.log((`💩 ${red.underline.bold("=> There was an error while copying files =>")} ${orange(err)}`));
132
- // } finally {
133
- // console.log("🐕" + blue.underline.bold(' => Copy files completed!'));
134
- // }
135
- // }
136
-
137
- // /**
138
- // * Edit Json files
139
- // * @param {string} filePath File path
140
- // * @param {string[]} keys Keys to edit
141
- // * @param {string[]} values Values to edit
142
- // * @returns {void}
143
- // */
144
- // async function editJson(filePath: string, keys: string[], values: string[] | Object[] ) {
145
- // try {
146
- // const data = await fs.readFile(filePath, 'utf8');
147
-
148
- // let jsonData;
149
- // try {
150
- // jsonData = JSON.parse(data);
151
- // } catch (parseError) {
152
- // console.log((`💩 ${red.underline.bold("=> Error parsing JSON =>")} ${orange(parseError)}`));
153
- // return;
154
- // }
155
-
156
- // for (const key of keys){
157
- // const index = keys.indexOf(key);
158
- // const value = values[index];
159
- // jsonData[key] = value;
160
- // }
161
-
162
- // const updatedJsonData = JSON.stringify(jsonData, null, 2);
163
- // await fs.writeFile(filePath, updatedJsonData, 'utf8');
164
- // } catch (err) {
165
- // console.log((`💩 ${red.underline.bold("=> Error editing JSON Data =>")} ${orange(err)}`));
166
- // } finally {
167
- // console.log("🐕" + blue.underline(` => Updated file ${orange(filePath)}`));
168
- // }
169
- // }
170
-
171
- // async function stringReplace(filePath: string, keys: string[], values: string[]) {
172
- // try {
173
- // let modifiedContent: string = '';
174
- // const data = await fs.readFile(filePath, 'utf8');
175
-
176
- // for (const key of keys){
177
- // const index = keys.indexOf(key);
178
- // const value = values[index];
179
- // const regex = new RegExp(`${key}`, 'g');
180
- // modifiedContent = data.replace(regex, `${value}`);
181
- // }
182
-
183
- // await fs.writeFile(filePath, modifiedContent, 'utf8');
184
- // } catch (err) {
185
- // console.log((`💩 ${red.underline.bold("=> During string replace =>")} ${orange(err)}`));
186
- // } finally {
187
- // console.log(blue.underline(`🐕 => Updated file ${orange(filePath)}`));
188
- // }
189
- // }
190
-
191
- const init_expo = () => {
192
- return Effect.gen(function*() {
193
- const config = yield* Config;
194
- const terminal = yield* Terminal.Terminal;
195
- const fs = yield* FileSystem.FileSystem;
196
- const path = yield* Path.Path;
197
-
198
- const yarn = Command.make(
199
- "yarn",
200
- "add",
201
- "nativewind",
202
- "react-native-reanimated@~3.17.4",
203
- "react-native-safe-area-context@5.4.0",
204
- "@wix/sdk@1.15.24",
205
- "@wix/data",
206
- "expo-standard-web-crypto",
207
- "effect",
208
- "node-libs-react-native",
209
- "util",
210
- "events",
211
- "tailwindcss-animate",
212
- ).pipe(
213
- Command.stdout("inherit"), // Stream stdout to process.stdout
214
- Command.exitCode // Get the exit code
215
- )
216
- const yarnVersion = Command.make(
217
- "yarn",
218
- "set",
219
- "version",
220
- "berry"
221
- ).pipe(
222
- Command.stdout("inherit"), // Stream stdout to process.stdout
223
- Command.exitCode // Get the exit code
224
- )
225
-
226
- const yarnDev = Command.make(
227
- "yarn",
228
- "add",
229
- "--dev",
230
- "tailwindcss@^3.4.17",
231
- "prettier-plugin-tailwindcss@^0.5.11",
232
- "@styled/typescript-styled-plugin",
233
- "typescript-eslint-language-service",
234
- "eslint-config-prettier",
235
- "eslint-plugin-jsdoc",
236
- "eslint-plugin-named-import-spacing",
237
- "eslint-plugin-only-warn",
238
- "eslint-plugin-react",
239
- "eslint-plugin-react-hooks",
240
- "eslint-plugin-simple-import-sort",
241
- "@next/eslint-plugin-next",
242
- "@styled/typescript-styled-plugin",
243
- "@stylelint/postcss-css-in-js",
244
- "@typescript-eslint/parser",
245
- "typescript-eslint",
246
- "typescript-eslint-language-service",
247
- "@total-typescript/ts-reset",
248
- "expo-doctor",
249
- "tsx",
250
- ).pipe(
251
- Command.stdout("inherit"), // Stream stdout to process.stdout
252
- Command.exitCode // Get the exit code
253
- )
254
-
255
- const npx = Command.make(
256
- "npx",
257
- "expo",
258
- "install",
259
- "tailwindcss-animate",
260
- "class-variance-authority",
261
- "clsx",
262
- "tailwind-merge",
263
- "expo-crypto",
264
- "react-dom",
265
- "react-native-web",
266
- "@expo/metro-runtime",
267
- "expo-system-ui"
268
- ).pipe(
269
- Command.stdout("inherit"), // Stream stdout to process.stdout
270
- Command.exitCode // Get the exit code
271
- )
272
-
273
- const projectName = config.config.cwd.split('/').pop() || 'expo-project';
274
-
275
- const appJsonRaw = yield* fs.readFile("app.json").pipe(Effect.catchAll((error) => {
276
- return Effect.succeed('{}');
277
- }))
278
- const lucyJsonRaw = yield* fs.readFile("lucy.json").pipe(Effect.catchAll((error) => {
279
- return Effect.succeed('{}');
280
- }))
281
- const appJSON = Schema.decodeUnknownSync(JsonSchema)(appJsonRaw.toString()) as any;
282
- const lucyJSON = Schema.decodeUnknownSync(JsonSchema)(lucyJsonRaw.toString()) as any;
283
-
284
- const expoAppReady = appJSON.expo ? true : false;
285
- const lucyInitialized = lucyJSON.initialized ? true : false;
286
- const gitPresent = yield* fs.exists(config.config.cwd + '/.git')
287
-
288
- const files = yield* fs.readDirectory(config.config.cwd);
289
- const nonGitFiles = files.filter(file => file !== '.git');
290
-
291
- if(!gitPresent) return yield* Effect.logError("No git repository found. Please initialize a git repository before running this command.");
292
- if(nonGitFiles.length > 0) return yield* Effect.logError("The current directory is not empty. Please run this command in an empty directory.");
293
-
294
- if(!expoAppReady) {
295
- const initExpo = Command.make("npx", "create-expo-app@latest", projectName, "--template", "blank-typescript", "--no-install").pipe(
296
- Command.stdout("inherit"), // Stream stdout to process.stdout
297
- Command.exitCode // Get the exit code
298
- )
299
- yield* initExpo
300
-
301
- const projectPath = path.join(config.config.cwd, projectName)
302
-
303
- const projectFiles = yield* fs.readDirectory(projectPath)
304
- yield* Effect.forEach(
305
- projectFiles.filter(file => file !== '.git'),
306
- (file) => fs.copy(path.join(projectPath, file), path.join(config.config.cwd, file), { overwrite: true }),
307
- { discard: true }
308
- )
309
- yield* fs.remove(projectPath, { recursive: true })
310
- }
311
- if(lucyInitialized) return yield* Effect.logError("Lucy is already initialized in this project. Please run this command in an empty directory.");
312
-
313
- const baseFiles = yield* fs.readDirectory(config.config.filesFolder + '/expo')
314
- yield* Effect.forEach(
315
- baseFiles,
316
- (file) => fs.copy(path.join(config.config.filesFolder, 'expo', file), path.join(config.config.cwd, file), { overwrite: true })
317
- )
318
-
319
- const newScripts = {
320
- "dev": "expo start",
321
- "start": "expo start",
322
- "android": "expo start --android",
323
- "ios": "expo start --ios",
324
- "web": "expo start --web",
325
- "reset": "tsx ./scripts/reset-project.ts",
326
- "format": "prettier --write \"./*.json\" \"**/*.{ts,tsx,md,json,jsonc,json5}\"",
327
- "prebuild": "expo prebuild",
328
- "pods": "npxpod-install",
329
- "build:dev": "eas build --local --profile development",
330
- "build:sim": "eas build --local --profile ios-simulator",
331
- "build:prev": "eas build --local --profile preview",
332
- "build:prod": "eas build --local --profile production",
333
- "build:web": "expo export --platform web",
334
- "doctor": "expo-doctor",
335
- "eas-build-pre-install": "corepack enable && yarn set version 4"
336
- }
337
-
338
- const packageJsonPath = path.join(config.config.cwd, "package.json")
339
- const packageJsonRaw = yield* fs.readFile(packageJsonPath)
340
- const packageJson = Schema.decodeUnknownSync(JsonSchema)(packageJsonRaw.toString()) as any;
341
-
342
- packageJson.scripts = {
343
- ...packageJson.scripts,
344
- ...newScripts,
345
- };
346
- packageJson.resolutions = {
347
- ...packageJson.resolutions,
348
- };
349
- packageJson.expo = {
350
- doctor: {
351
- reactNativeDirectoryCheck: {
352
- listUnknownPackages: false,
353
- },
354
- }
355
- }
356
-
357
- yield* fs.writeFileString(path.join(config.config.cwd, 'package.json'), JSON.stringify(packageJson, null, 2));
358
- yield* fs.remove(path.join(config.config.cwd, "package-lock.json"), { force: true })
359
-
360
-
361
- let res = yield* yarnVersion;
362
- if (res !== 0) {
363
- return yield* Effect.logError("Failed to set Yarn version. Please check the error message above.");
364
- }
365
- res = yield* yarn
366
- if (res !== 0) {
367
- return yield* Effect.logError("Failed to install dependencies. Please check the error message above.");
368
- }
369
- res = yield* yarnDev
370
- if (res !== 0) {
371
- return yield* Effect.logError("Failed to install dev dependencies. Please check the error message above.");
372
- }
373
- res = yield* npx
374
- if (res !== 0) {
375
- return yield* Effect.logError("Failed to install Expo dependencies. Please check the error message above.");
376
- }
377
- })
378
- }
379
-
380
- export const init = () => {
381
- return Effect.gen(function* (_) {
382
- const config = yield* Config;
383
- if(config.config.action.type === undefined) {
384
- return yield* Effect.fail("No Params Provided");
385
- }
386
-
387
- if(config.config.action.type === 'expo') {
388
- return yield* init_expo();
389
- }
390
-
391
- })
392
- }
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes