lucy-cli 2.0.0-beta.1 → 2.0.0-beta.11
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.
- package/.cursorignore +4 -0
- package/.wix/debug.log +10 -0
- package/README.md +117 -102
- package/dist/args.js +41 -1
- package/dist/args.js.map +1 -1
- package/dist/commands/exec.d.ts +2 -2
- package/dist/commands/exec.js +15 -13
- package/dist/commands/exec.js.map +1 -1
- package/dist/commands/home.d.ts +2 -2
- package/dist/commands/home.js +25 -2
- package/dist/commands/home.js.map +1 -1
- package/dist/commands/install.d.ts +1 -0
- package/dist/commands/install.js +29 -16
- package/dist/commands/install.js.map +1 -1
- package/dist/helpers.d.ts +1 -1
- package/dist/helpers.js +1 -8
- package/dist/helpers.js.map +1 -1
- package/dist/index.d.ts +0 -1
- package/dist/index.js +4 -2
- package/dist/index.js.map +1 -1
- package/dist/init/blocks.d.ts +1 -1
- package/dist/init/blocks.js +2 -2
- package/dist/init/cargo.d.ts +1 -1
- package/dist/init/cargo.js +2 -2
- package/dist/init/expo.d.ts +1 -1
- package/dist/init/expo.js +2 -2
- package/dist/init/index.d.ts +1 -2
- package/dist/init/index.js +10 -1
- package/dist/init/index.js.map +1 -1
- package/dist/init/monorepo.d.ts +1 -1
- package/dist/init/monorepo.js +2 -2
- package/dist/init/tauri.d.ts +1 -1
- package/dist/init/tauri.js +2 -2
- package/dist/init/velo.d.ts +1 -1
- package/dist/init/velo.js +3 -2
- package/dist/init/velo.js.map +1 -1
- package/dist/schemas/index.d.ts +1 -0
- package/dist/schemas/index.js +1 -0
- package/dist/schemas/index.js.map +1 -1
- package/dist/schemas/lucy.d.ts +2 -2
- package/dist/schemas/lucy.js +1 -1
- package/dist/schemas/lucy.js.map +1 -1
- package/dist/tasks/Gulpfile.js +3 -3
- package/dist/tasks/Gulpfile.js.map +1 -1
- package/dist/tasks/gulp/checks.js +12 -11
- package/dist/tasks/gulp/checks.js.map +1 -1
- package/dist/tasks/gulp/watchers.js +3 -3
- package/dist/tasks/gulp/watchers.js.map +1 -1
- package/dist/tasks/index.d.ts +1 -1
- package/files/templates/Default[B]/files/.cursorignore +4 -0
- package/files/templates/Default[C]/files/.cursorignore +4 -0
- package/files/templates/Default[E]/files/.cursorignore +4 -0
- package/files/templates/Default[E]/files/app.config.ts +69 -0
- package/files/templates/{expo[D] → Default[E]}/files/assets/fonts/SpaceMono-Regular.ttf +0 -0
- package/files/templates/{expo[D] → Default[E]}/files/scripts/reset-project.ts +0 -0
- package/files/templates/Default[M]/files/.cursorignore +4 -0
- package/files/templates/Default[T]/files/.cursorignore +4 -0
- package/files/templates/expo verse[E]/files/.nvmrc +1 -0
- package/files/templates/expo verse[E]/files/.prettierignore +23 -0
- package/files/templates/expo verse[E]/files/.prettierrc.js +16 -0
- package/files/templates/expo verse[E]/files/.stylelintrc.json +8 -0
- package/files/templates/expo verse[E]/files/.vscode/extensions.json +10 -0
- package/files/templates/expo verse[E]/files/.vscode/launch.json +54 -0
- package/files/templates/expo verse[E]/files/.vscode/settings.json +30 -0
- package/files/templates/expo verse[E]/files/.vscode/tasks.json +0 -0
- package/files/templates/expo verse[E]/files/.yarnrc +1 -0
- package/files/templates/expo verse[E]/files/.yarnrc.yml +8 -0
- package/files/templates/expo verse[E]/files/App.tsx +63 -0
- package/files/templates/expo verse[E]/files/DEBUGGING.md +126 -0
- package/files/templates/expo verse[E]/files/README.md +45 -0
- package/files/templates/expo verse[E]/files/android/app/build.gradle +177 -0
- package/files/templates/expo verse[E]/files/android/app/debug.keystore +0 -0
- package/files/templates/expo verse[E]/files/android/app/proguard-rules.pro +14 -0
- package/files/templates/expo verse[E]/files/android/app/src/debug/AndroidManifest.xml +7 -0
- package/files/templates/expo verse[E]/files/android/app/src/main/AndroidManifest.xml +33 -0
- package/files/templates/expo verse[E]/files/android/app/src/main/java/so/sunnysideup/daily_verse/MainActivity.kt +65 -0
- package/files/templates/expo verse[E]/files/android/app/src/main/java/so/sunnysideup/daily_verse/MainApplication.kt +57 -0
- package/files/templates/expo verse[E]/files/android/app/src/main/res/drawable/ic_launcher_background.xml +6 -0
- package/files/templates/expo verse[E]/files/android/app/src/main/res/drawable/rn_edit_text_material.xml +37 -0
- package/files/templates/expo verse[E]/files/android/app/src/main/res/drawable-hdpi/splashscreen_logo.png +0 -0
- package/files/templates/expo verse[E]/files/android/app/src/main/res/drawable-mdpi/splashscreen_logo.png +0 -0
- package/files/templates/expo verse[E]/files/android/app/src/main/res/drawable-night-hdpi/splashscreen_logo.png +0 -0
- package/files/templates/expo verse[E]/files/android/app/src/main/res/drawable-night-mdpi/splashscreen_logo.png +0 -0
- package/files/templates/expo verse[E]/files/android/app/src/main/res/drawable-night-xhdpi/splashscreen_logo.png +0 -0
- package/files/templates/expo verse[E]/files/android/app/src/main/res/drawable-night-xxhdpi/splashscreen_logo.png +0 -0
- package/files/templates/expo verse[E]/files/android/app/src/main/res/drawable-night-xxxhdpi/splashscreen_logo.png +0 -0
- package/files/templates/expo verse[E]/files/android/app/src/main/res/drawable-xhdpi/splashscreen_logo.png +0 -0
- package/files/templates/expo verse[E]/files/android/app/src/main/res/drawable-xxhdpi/splashscreen_logo.png +0 -0
- package/files/templates/expo verse[E]/files/android/app/src/main/res/drawable-xxxhdpi/splashscreen_logo.png +0 -0
- package/files/templates/expo verse[E]/files/android/app/src/main/res/mipmap-anydpi-v26/ic_launcher.xml +6 -0
- package/files/templates/expo verse[E]/files/android/app/src/main/res/mipmap-anydpi-v26/ic_launcher_round.xml +6 -0
- package/files/templates/expo verse[E]/files/android/app/src/main/res/mipmap-hdpi/ic_launcher.webp +0 -0
- package/files/templates/expo verse[E]/files/android/app/src/main/res/mipmap-hdpi/ic_launcher_foreground.webp +0 -0
- package/files/templates/expo verse[E]/files/android/app/src/main/res/mipmap-hdpi/ic_launcher_monochrome.webp +0 -0
- package/files/templates/expo verse[E]/files/android/app/src/main/res/mipmap-hdpi/ic_launcher_round.webp +0 -0
- package/files/templates/expo verse[E]/files/android/app/src/main/res/mipmap-mdpi/ic_launcher.webp +0 -0
- package/files/templates/expo verse[E]/files/android/app/src/main/res/mipmap-mdpi/ic_launcher_foreground.webp +0 -0
- package/files/templates/expo verse[E]/files/android/app/src/main/res/mipmap-mdpi/ic_launcher_monochrome.webp +0 -0
- package/files/templates/expo verse[E]/files/android/app/src/main/res/mipmap-mdpi/ic_launcher_round.webp +0 -0
- package/files/templates/expo verse[E]/files/android/app/src/main/res/mipmap-xhdpi/ic_launcher.webp +0 -0
- package/files/templates/expo verse[E]/files/android/app/src/main/res/mipmap-xhdpi/ic_launcher_foreground.webp +0 -0
- package/files/templates/expo verse[E]/files/android/app/src/main/res/mipmap-xhdpi/ic_launcher_monochrome.webp +0 -0
- package/files/templates/expo verse[E]/files/android/app/src/main/res/mipmap-xhdpi/ic_launcher_round.webp +0 -0
- package/files/templates/expo verse[E]/files/android/app/src/main/res/mipmap-xxhdpi/ic_launcher.webp +0 -0
- package/files/templates/expo verse[E]/files/android/app/src/main/res/mipmap-xxhdpi/ic_launcher_foreground.webp +0 -0
- package/files/templates/expo verse[E]/files/android/app/src/main/res/mipmap-xxhdpi/ic_launcher_monochrome.webp +0 -0
- package/files/templates/expo verse[E]/files/android/app/src/main/res/mipmap-xxhdpi/ic_launcher_round.webp +0 -0
- package/files/templates/expo verse[E]/files/android/app/src/main/res/mipmap-xxxhdpi/ic_launcher.webp +0 -0
- package/files/templates/expo verse[E]/files/android/app/src/main/res/mipmap-xxxhdpi/ic_launcher_foreground.webp +0 -0
- package/files/templates/expo verse[E]/files/android/app/src/main/res/mipmap-xxxhdpi/ic_launcher_monochrome.webp +0 -0
- package/files/templates/expo verse[E]/files/android/app/src/main/res/mipmap-xxxhdpi/ic_launcher_round.webp +0 -0
- package/files/templates/expo verse[E]/files/android/app/src/main/res/values/colors.xml +6 -0
- package/files/templates/expo verse[E]/files/android/app/src/main/res/values/strings.xml +7 -0
- package/files/templates/expo verse[E]/files/android/app/src/main/res/values/styles.xml +12 -0
- package/files/templates/expo verse[E]/files/android/app/src/main/res/values-night/colors.xml +3 -0
- package/files/templates/expo verse[E]/files/android/build.gradle +37 -0
- package/files/templates/expo verse[E]/files/android/gradle/wrapper/gradle-wrapper.jar +0 -0
- package/files/templates/expo verse[E]/files/android/gradle/wrapper/gradle-wrapper.properties +7 -0
- package/files/templates/expo verse[E]/files/android/gradle.properties +59 -0
- package/files/templates/expo verse[E]/files/android/gradlew +251 -0
- package/files/templates/expo verse[E]/files/android/gradlew.bat +94 -0
- package/files/templates/expo verse[E]/files/android/settings.gradle +39 -0
- package/files/templates/expo verse[E]/files/app.config.ts +77 -0
- package/files/templates/expo verse[E]/files/assets/data/de.csv +949 -0
- package/files/templates/expo verse[E]/files/assets/data/en.csv +949 -0
- package/files/templates/expo verse[E]/files/assets/fonts/PlayfairDisplay-Black.ttf +0 -0
- package/files/templates/expo verse[E]/files/assets/fonts/PlayfairDisplay-BlackItalic.ttf +0 -0
- package/files/templates/expo verse[E]/files/assets/fonts/PlayfairDisplay-Bold.ttf +0 -0
- package/files/templates/expo verse[E]/files/assets/fonts/PlayfairDisplay-BoldItalic.ttf +0 -0
- package/files/templates/expo verse[E]/files/assets/fonts/PlayfairDisplay-ExtraBold.ttf +0 -0
- package/files/templates/expo verse[E]/files/assets/fonts/PlayfairDisplay-ExtraBoldItalic.ttf +0 -0
- package/files/templates/expo verse[E]/files/assets/fonts/PlayfairDisplay-Italic.ttf +0 -0
- package/files/templates/expo verse[E]/files/assets/fonts/PlayfairDisplay-Medium.ttf +0 -0
- package/files/templates/expo verse[E]/files/assets/fonts/PlayfairDisplay-MediumItalic.ttf +0 -0
- package/files/templates/expo verse[E]/files/assets/fonts/PlayfairDisplay-Regular.ttf +0 -0
- package/files/templates/expo verse[E]/files/assets/fonts/PlayfairDisplay-SemiBold.ttf +0 -0
- package/files/templates/expo verse[E]/files/assets/fonts/PlayfairDisplay-SemiBoldItalic.ttf +0 -0
- package/files/templates/expo verse[E]/files/assets/fonts/SpaceMono-Regular.ttf +0 -0
- package/files/templates/expo verse[E]/files/assets/images/andorid/background.png +0 -0
- package/files/templates/expo verse[E]/files/assets/images/android-dark.png +0 -0
- package/files/templates/expo verse[E]/files/assets/images/android-light.png +0 -0
- package/files/templates/expo verse[E]/files/assets/images/background.png +0 -0
- package/files/templates/expo verse[E]/files/assets/images/ios-dark.png +0 -0
- package/files/templates/expo verse[E]/files/assets/images/ios-light.png +0 -0
- package/files/templates/expo verse[E]/files/assets/images/ios-tinted.png +0 -0
- package/files/templates/expo verse[E]/files/assets/images/splash-icon-dark.png +0 -0
- package/files/templates/expo verse[E]/files/assets/images/splash-icon-light.png +0 -0
- package/files/templates/expo verse[E]/files/babel.config.js +10 -0
- package/files/templates/expo verse[E]/files/components/.gitkeep +0 -0
- package/files/templates/expo verse[E]/files/components/MainScreen.tsx +299 -0
- package/files/templates/expo verse[E]/files/components/Share.tsx +132 -0
- package/files/templates/expo verse[E]/files/components/ui/.gitkeep +0 -0
- package/files/templates/expo verse[E]/files/components/ui/dev.tsx +48 -0
- package/files/templates/expo verse[E]/files/constants/config.ts +30 -0
- package/files/templates/expo verse[E]/files/constants/theme.ts +18 -0
- package/files/templates/expo verse[E]/files/data/de.csv +219 -0
- package/files/templates/expo verse[E]/files/data/en.csv +219 -0
- package/files/templates/expo verse[E]/files/data/version.json +4 -0
- package/files/templates/expo verse[E]/files/eas.json +47 -0
- package/files/templates/expo verse[E]/files/eslint.config.mjs +185 -0
- package/files/templates/expo verse[E]/files/global.css +47 -0
- package/files/templates/expo verse[E]/files/hooks/useColorScheme.ts +17 -0
- package/files/templates/expo verse[E]/files/index.ts +28 -0
- package/files/templates/expo verse[E]/files/lib/content.ts +31 -0
- package/files/templates/expo verse[E]/files/lib/data.ts +180 -0
- package/files/templates/expo verse[E]/files/lib/helper.ts +54 -0
- package/files/templates/expo verse[E]/files/lib/index.ts +21 -0
- package/files/templates/expo verse[E]/files/lib/state.ts +128 -0
- package/files/templates/expo verse[E]/files/lib/storage.ts +17 -0
- package/files/templates/expo verse[E]/files/lib/taskManager/index.ts +38 -0
- package/files/templates/expo verse[E]/files/lib/taskManager/loadData.ts +14 -0
- package/files/templates/expo verse[E]/files/lib/utils/index.ts +11 -0
- package/files/templates/expo verse[E]/files/lib/utils/polyfills.ts +29 -0
- package/files/templates/expo verse[E]/files/lib/utils/screenshot.ts +77 -0
- package/files/templates/expo verse[E]/files/lucy.json +8 -0
- package/files/templates/expo verse[E]/files/metro.config.js +81 -0
- package/files/templates/expo verse[E]/files/models/index.ts +28 -0
- package/files/templates/expo verse[E]/files/nativewind-env.d.ts +1 -0
- package/files/templates/expo verse[E]/files/package.json +102 -0
- package/files/templates/expo verse[E]/files/pnpm-workspace.yaml +3 -0
- package/files/templates/expo verse[E]/files/scripts/convert-verses.ts +309 -0
- package/files/templates/expo verse[E]/files/scripts/move-artifacts.ts +83 -0
- package/files/templates/expo verse[E]/files/scripts/reset-project.ts +116 -0
- package/files/templates/expo verse[E]/files/tailwind.config.js +63 -0
- package/files/templates/expo verse[E]/files/tsconfig.json +45 -0
- package/files/templates/expo verse[E]/files/types/index.ts +4 -0
- package/files/templates/expo verse[E]/files/types/reset.d.ts +1 -0
- package/files/templates/expo verse[E]/lucy.json +86 -0
- package/files/templates/velo[D]/files/.cursorignore +4 -0
- package/files/templates/velo[D]/files/.yarnrc.yml +1 -2
- package/files/templates/velo[D]/files/local.tsconfig.json +6 -5
- package/files/templates/velo[D]/files/typescript/backend/config/authz.ts +47 -0
- package/files/templates/velo[D]/files/typescript/backend/config/env.ts +8 -0
- package/files/templates/velo[D]/files/typescript/backend/config/index.ts +26 -0
- package/files/templates/velo[D]/files/typescript/backend/config/mail.ts +10 -0
- package/files/templates/velo[D]/files/typescript/backend/config/nats.ts +6 -0
- package/files/templates/velo[D]/files/typescript/public/config/env.ts +9 -0
- package/files/templates/velo[D]/files/typescript/public/config/index.ts +76 -0
- package/files/templates/velo[D]/files/typescript/public/config/locales.ts +30 -0
- package/files/templates/velo[D]/files/typescript/public/config/theme.ts +110 -0
- package/files/templates/velo[D]/files/typescript/public/i18n/default.ts +123 -0
- package/files/templates/velo[D]/files/typescript/public/i18n/en.ts +117 -0
- package/files/templates/velo[D]/files/typescript/public/models/collections/member_roles.mode.ts +21 -0
- package/files/templates/velo[D]/files/typescript/public/models/collections/organization.model.ts +38 -0
- package/files/templates/velo[D]/files/typescript/public/models/collections/plan.model.ts +94 -0
- package/files/templates/velo[D]/files/typescript/public/models/collections/stage.model.ts +14 -0
- package/files/templates/velo[D]/files/typescript/public/models/collections/subscriptions.model.ts +80 -0
- package/files/templates/velo[D]/files/typescript/public/models/collections/tag.model.ts +15 -0
- package/files/templates/velo[D]/files/typescript/public/models/collections/translations.model.ts +16 -0
- package/files/templates/velo[D]/files/typescript/public/models/modules/authz.model.ts +31 -0
- package/files/templates/velo[D]/files/typescript/public/models/modules/organization.ts +20 -0
- package/files/templates/velo[D]/files/typescript/public/models/splitwise.model.ts +18 -0
- package/files/templates/velo[D]/files/typescript/public/models/store/local.model.ts +10 -0
- package/files/templates/velo[D]/files/typescript/public/models/store/memory.model.ts +10 -0
- package/files/templates/velo[D]/files/typescript/public/models/store/session.model.ts +10 -0
- package/files/templates/velo[D]/files/typescript/public/models/wix/ecom/payment.ts +236 -0
- package/files/templates/velo[D]/lucy.json +36 -26
- package/lucy +4 -0
- package/lucy.jpg +0 -0
- package/mitarbeiter-login.html +188 -0
- package/old/index.ts +0 -0
- package/package.json +15 -14
- package/pnpm-workspace.yaml +6 -0
- package/src/args.ts +41 -1
- package/src/commands/exec.ts +22 -18
- package/src/commands/home.ts +36 -2
- package/src/commands/install.ts +41 -21
- package/src/helpers.ts +1 -9
- package/src/index.ts +4 -2
- package/src/init/blocks.ts +2 -2
- package/src/init/cargo.ts +2 -2
- package/src/init/expo.ts +2 -2
- package/src/init/index.ts +10 -2
- package/src/init/monorepo.ts +2 -2
- package/src/init/tauri.ts +2 -2
- package/src/init/velo.ts +4 -3
- package/src/schemas/index.ts +2 -0
- package/src/schemas/lucy.ts +1 -1
- package/src/tasks/Gulpfile.ts +3 -3
- package/src/tasks/gulp/checks.ts +15 -14
- package/src/tasks/gulp/watchers.ts +3 -3
- /package/files/templates/{block[D] → Default[B]}/files/.stylelintrc.js +0 -0
- /package/files/templates/{block[D] → Default[B]}/lucy.json +0 -0
- /package/files/templates/{cargo[D] → Default[C]}/files/.env +0 -0
- /package/files/templates/{cargo[D] → Default[C]}/files/Cargo.toml +0 -0
- /package/files/templates/{cargo[D] → Default[C]}/files/Makefile.toml +0 -0
- /package/files/templates/{cargo[D] → Default[C]}/files/build/main.rs +0 -0
- /package/files/templates/{cargo[D] → Default[C]}/files/config/beta.json +0 -0
- /package/files/templates/{cargo[D] → Default[C]}/files/config/ci.json +0 -0
- /package/files/templates/{cargo[D] → Default[C]}/files/config/default.json +0 -0
- /package/files/templates/{cargo[D] → Default[C]}/files/config/development.json +0 -0
- /package/files/templates/{cargo[D] → Default[C]}/files/config/produktion.json +0 -0
- /package/files/templates/{cargo[D] → Default[C]}/files/config/stage.json +0 -0
- /package/files/templates/{cargo[D] → Default[C]}/files/locales/todo.yml +0 -0
- /package/files/templates/{cargo[D] → Default[C]}/files/public/index.html +0 -0
- /package/files/templates/{cargo[D] → Default[C]}/lucy.json +0 -0
- /package/files/templates/{expo[D] → Default[E]}/files/.nvmrc +0 -0
- /package/files/templates/{expo[D] → Default[E]}/files/.prettierignore +0 -0
- /package/files/templates/{expo[D] → Default[E]}/files/.prettierrc.js +0 -0
- /package/files/templates/{expo[D] → Default[E]}/files/.stylelintrc.js +0 -0
- /package/files/templates/{expo[D] → Default[E]}/files/.yarnrc +0 -0
- /package/files/templates/{expo[D] → Default[E]}/files/.yarnrc.yml +0 -0
- /package/files/templates/{expo[D] → Default[E]}/files/README.md +0 -0
- /package/files/templates/{expo[D] → Default[E]}/files/assets/images/adaptive-icon.png +0 -0
- /package/files/templates/{expo[D] → Default[E]}/files/assets/images/favicon.png +0 -0
- /package/files/templates/{expo[D] → Default[E]}/files/assets/images/icon.png +0 -0
- /package/files/templates/{expo[D] → Default[E]}/files/assets/images/splash-icon.png +0 -0
- /package/files/templates/{expo[D] → Default[E]}/files/babel.config.js +0 -0
- /package/files/templates/{expo[D] → Default[E]}/files/components/.gitkeep +0 -0
- /package/files/templates/{expo[D] → Default[E]}/files/components/ui/.gitkeep +0 -0
- /package/files/templates/{expo[D] → Default[E]}/files/constants/theme.ts +0 -0
- /package/files/templates/{expo[D] → Default[E]}/files/eas.json +0 -0
- /package/files/templates/{expo[D] → Default[E]}/files/eslint.config.mjs +0 -0
- /package/files/templates/{expo[D] → Default[E]}/files/global.css +0 -0
- /package/files/templates/{expo[D] → Default[E]}/files/hooks/useColorScheme.ts +0 -0
- /package/files/templates/{expo[D] → Default[E]}/files/index.ts +0 -0
- /package/files/templates/{expo[D] → Default[E]}/files/lib/data.ts +0 -0
- /package/files/templates/{expo[D] → Default[E]}/files/lib/utils/index.ts +0 -0
- /package/files/templates/{expo[D] → Default[E]}/files/lib/utils/polyfills.ts +0 -0
- /package/files/templates/{expo[D] → Default[E]}/files/lib/wix/client.ts +0 -0
- /package/files/templates/{expo[D] → Default[E]}/files/lib/wix/error.ts +0 -0
- /package/files/templates/{expo[D] → Default[E]}/files/lib/wix/index.ts +0 -0
- /package/files/templates/{expo[D] → Default[E]}/files/metro.config.js +0 -0
- /package/files/templates/{expo[D] → Default[E]}/files/nativewind-env.d.ts +0 -0
- /package/files/templates/{expo[D] → Default[E]}/files/pnpm-workspace.yaml +0 -0
- /package/files/templates/{expo[D] → Default[E]}/files/tailwind.config.js +0 -0
- /package/files/templates/{expo[D] → Default[E]}/files/tsconfig.json +0 -0
- /package/files/templates/{expo[D] → Default[E]}/files/types/reset.d.ts +0 -0
- /package/files/templates/{expo[D] → Default[E]}/lucy.json +0 -0
- /package/files/templates/{monorepo[D] → Default[M]}/files/.editorconfig +0 -0
- /package/files/templates/{monorepo[D] → Default[M]}/files/.nvmrc +0 -0
- /package/files/templates/{monorepo[D] → Default[M]}/files/.prettierignore +0 -0
- /package/files/templates/{monorepo[D] → Default[M]}/files/.prettierrc.json +0 -0
- /package/files/templates/{monorepo[D] → Default[M]}/files/.stylelintrc.js +0 -0
- /package/files/templates/{monorepo[D] → Default[M]}/files/.yarnrc +0 -0
- /package/files/templates/{monorepo[D] → Default[M]}/files/.yarnrc.yml +0 -0
- /package/files/templates/{monorepo[D] → Default[M]}/files/README.md +0 -0
- /package/files/templates/{monorepo[D] → Default[M]}/files/currents.config.ts +0 -0
- /package/files/templates/{monorepo[D] → Default[M]}/files/nx.json +0 -0
- /package/files/templates/{monorepo[D] → Default[M]}/files/pnpm-workspace.yaml +0 -0
- /package/files/templates/{monorepo[D] → Default[M]}/files/tsconfig.json +0 -0
- /package/files/templates/{monorepo[D] → Default[M]}/files/typedoc.json +0 -0
- /package/files/templates/{monorepo[D] → Default[M]}/files/vitest.config.ts +0 -0
- /package/files/templates/{monorepo[D] → Default[M]}/lucy.json +0 -0
- /package/files/templates/{tauri[D] → Default[T]}/lucy.json +0 -0
package/.cursorignore
ADDED
package/.wix/debug.log
ADDED
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
----- CLI crash report at 2025-08-10T16:11:35.320Z
|
|
2
|
+
Error Trace
|
|
3
|
+
FailedToIdentifyProgramFlow: FailedToIdentifyProgramFlow
|
|
4
|
+
at _Command.<anonymous> (/Users/gradlon/.nvm/versions/node/v20.11.1/lib/node_modules/@wix/cli/src/program.ts:73:15)
|
|
5
|
+
at _Command.emit (node:events:518:28)
|
|
6
|
+
at _Command._parseCommand (/Users/gradlon/.nvm/versions/node/v20.11.1/lib/node_modules/node_modules/commander/lib/command.js:1607:14)
|
|
7
|
+
at _Command.parseAsync (/Users/gradlon/.nvm/versions/node/v20.11.1/lib/node_modules/node_modules/commander/lib/command.js:1104:16)
|
|
8
|
+
at <anonymous> (/Users/gradlon/.nvm/versions/node/v20.11.1/lib/node_modules/@wix/cli/src/index.tsx:80:39)
|
|
9
|
+
Error Info
|
|
10
|
+
{}
|
package/README.md
CHANGED
|
@@ -1,46 +1,59 @@
|
|
|
1
1
|
# Lucy-CLI
|
|
2
2
|
|
|
3
|
-
|
|
3
|
+
<div style="float: right; margin: 0 0 30px 30px;">
|
|
4
|
+
<img src="lucy.jpg" alt="Lucy-CLI" width="200" height="200" style="border-radius: 10px; box-shadow: 0 4px 8px rgba(0,0,0,0.1);">
|
|
5
|
+
</div>
|
|
4
6
|
|
|
5
7
|
## Motivation
|
|
6
8
|
|
|
7
|
-
Lucy-CLI was developed out of a personal need to gain full TypeScript support for Wix Velo projects. Typically, using Wix
|
|
9
|
+
Lucy-CLI was developed out of a personal need to gain full TypeScript support for Wix Velo projects. Typically, using Wix's GitHub integration provides JSON docs and basic type support, but I aimed for a more integrated TypeScript experience, especially for larger projects that benefit from enhanced type safety.
|
|
8
10
|
|
|
9
11
|
Lucy, my loyal dog, accompanied me during long nights working on a major project where I developed this CLI. Her companionship and resilience inspired the name "Lucy-CLI."
|
|
10
12
|
|
|
11
|
-
##
|
|
13
|
+
## Important Notes Before Using Lucy-CLI
|
|
12
14
|
|
|
13
15
|
This CLI is still in development and may have bugs. Please use it with caution.
|
|
14
|
-
Libraries are expected to have the same folder structure as the main typescript folder except for the pages folder.
|
|
15
|
-
(backend, public, styles)
|
|
16
|
-
The lucy CLI is opinionated and may not work with all projects.
|
|
17
16
|
|
|
18
|
-
|
|
19
|
-
Make sure you have yarn installed on your machine and it is set to version 3.
|
|
17
|
+
### Project Types Overview
|
|
20
18
|
|
|
21
|
-
|
|
22
|
-
yarn set <version>
|
|
23
|
-
```
|
|
24
|
-
|
|
25
|
-
The composite and declaration tsconfig setting int need to be set to false in order to reexport types from the lib folder.
|
|
26
|
-
This is not ideal but it is a limitation of the current version of the CLI.
|
|
19
|
+
Lucy-CLI supports multiple project types, each with different requirements and configurations:
|
|
27
20
|
|
|
28
|
-
|
|
29
|
-
|
|
21
|
+
#### Wix Velo Projects (`init velo`)
|
|
22
|
+
- **Purpose**: Full TypeScript support for Wix Velo development
|
|
23
|
+
- **Requirements**:
|
|
24
|
+
- Libraries must have the same folder structure as the main TypeScript folder (backend, public, styles)
|
|
25
|
+
- Composite and declaration tsconfig settings must be set to false for type reexport
|
|
26
|
+
- **Limitations**: Opinionated structure - may not work with all projects
|
|
30
27
|
|
|
31
|
-
|
|
28
|
+
**Backend Endpoint Import Pattern:**
|
|
29
|
+
```javascript
|
|
32
30
|
// eslint-disable-next-line @typescript-eslint/ban-ts-comment
|
|
33
31
|
//@ts-ignore
|
|
34
32
|
import { initialize, InitResponse } from 'backend/lib/initialize.web';
|
|
35
33
|
```
|
|
36
34
|
|
|
35
|
+
#### Other Project Types
|
|
36
|
+
- **Expo** (`init expo`): React Native with Expo framework
|
|
37
|
+
- **Blocks** (`init blocks`): Wix Blocks development
|
|
38
|
+
- **Monorepo** (`init monorepo`): Nx-based monorepo setup
|
|
39
|
+
- **Tauri** (`init tauri`): Desktop applications with Tauri
|
|
40
|
+
- **Cargo** (`init cargo`): Rust projects
|
|
41
|
+
- **Wix SDK** (`init wix-sdk`): Wix SDK integration
|
|
42
|
+
|
|
43
|
+
### Template System
|
|
44
|
+
|
|
45
|
+
Lucy-CLI uses a centralized template system located at `~/.lucy-cli` (your home directory). This folder contains:
|
|
46
|
+
- Default project configurations
|
|
47
|
+
- File structure templates for each project type
|
|
48
|
+
- Customizable settings and configurations
|
|
49
|
+
|
|
37
50
|
## Contributing
|
|
38
51
|
|
|
39
|
-
|
|
52
|
+
Contributions are welcome! Please submit issues and pull requests, and I will merge them if they fit the project's goals.
|
|
40
53
|
|
|
41
54
|
## What It Does
|
|
42
55
|
|
|
43
|
-
Lucy-CLI is designed to streamline the setup and management of TypeScript within Wix Velo projects, providing tools to enhance code quality and reduce development time. Here
|
|
56
|
+
Lucy-CLI is designed to streamline the setup and management of TypeScript within Wix Velo projects, providing tools to enhance code quality and reduce development time. Here's what it offers:
|
|
44
57
|
|
|
45
58
|
1. **ESLint Configuration**
|
|
46
59
|
- Adds ESLint with a default configuration (customizable post-init) to maintain consistent code style and prevent common errors.
|
|
@@ -55,7 +68,7 @@ Lucy-CLI is designed to streamline the setup and management of TypeScript within
|
|
|
55
68
|
- Includes support for git submodules, providing full type support within submodules and enabling the use of libraries and types across projects.
|
|
56
69
|
- To add a submodule, include the following in the `lucy.json` file:
|
|
57
70
|
|
|
58
|
-
```
|
|
71
|
+
```json
|
|
59
72
|
"modules": {
|
|
60
73
|
"<repoName>": {
|
|
61
74
|
"url": "String",
|
|
@@ -69,124 +82,126 @@ Lucy-CLI is designed to streamline the setup and management of TypeScript within
|
|
|
69
82
|
5. **Configurable Setup**
|
|
70
83
|
- After initialization, Lucy-CLI creates a `lucy-config.json` configuration file where you can modify settings, add dev packages, specify Wix packages, and configure git submodules.
|
|
71
84
|
|
|
72
|
-
6. **Execute
|
|
85
|
+
6. **Execute Render Functions**
|
|
73
86
|
- Lucy-CLI can execute render functions located in the backend template folder, allowing you to test render functions locally.
|
|
74
87
|
|
|
75
|
-
|
|
88
|
+
7. **Compile SCSS Files**
|
|
76
89
|
- Lucy-CLI can compile SCSS files to CSS files.
|
|
77
|
-
- It compiles styles/global.scss file to global.css
|
|
90
|
+
- It compiles the `styles/global.scss` file to `global.css`.
|
|
78
91
|
|
|
79
92
|
8. **Wix NPM Package Installation**
|
|
80
93
|
- Lucy-CLI can install Wix npm packages from the `lucy.json` file.
|
|
81
94
|
|
|
82
|
-
|
|
95
|
+
9. **Testing with Vitest**
|
|
83
96
|
- Lucy-CLI can run tests with Vitest.
|
|
84
|
-
- It runs tests located backend folder with
|
|
85
|
-
-
|
|
86
|
-
- Vitest
|
|
87
|
-
- You can add additional mock folders in vitest.config.ts file.
|
|
97
|
+
- It runs tests located in the backend folder with file names ending with `.spec.ts`.
|
|
98
|
+
- It creates a code coverage report in the coverage folder in the lib folders and TypeScript folders.
|
|
99
|
+
- Vitest looks for mocks in the TypeScript folder and lib folder.
|
|
100
|
+
- You can add additional mock folders in the `vitest.config.ts` file.
|
|
88
101
|
|
|
89
102
|
10. **Linting with ESLint**
|
|
90
103
|
- Lucy-CLI can lint the code with ESLint.
|
|
91
104
|
- It uses the ESLint configuration in the `.eslintrc.cjs` file in the project directory.
|
|
92
105
|
|
|
93
|
-
11. **Add
|
|
106
|
+
11. **Add Git Version During Production Build**
|
|
94
107
|
- Lucy-CLI can add the git version to the production build.
|
|
95
|
-
- It adds the git version to the `public/constant/env.ts` file in the public folder under the key gitTag
|
|
96
|
-
|
|
97
|
-
|
|
108
|
+
- It adds the git version to the `public/constant/env.ts` file in the public folder under the key `gitTag`.
|
|
109
|
+
|
|
110
|
+
12. **Use Velo-Sync to Synchronize Local Collections with Wix**
|
|
111
|
+
- Lucy-CLI can synchronize local collections with Wix collections.
|
|
98
112
|
- More information can be found in the [velo-sync](https://www.npmjs.com/package/velo-sync) documentation.
|
|
99
113
|
|
|
100
114
|
13. **Synchronize `package.json` with `lucy.json`**
|
|
101
|
-
-
|
|
115
|
+
- Lucy-CLI can synchronize dependencies from your project's `package.json` directly into the `lucy.json` configuration. The `dependencies` are mapped to `wixPackages` and `devDependencies` are mapped to `devPackages`.
|
|
102
116
|
|
|
103
117
|
14. **Manage CLI Templates**
|
|
104
|
-
-
|
|
118
|
+
- Lucy-CLI uses a templates folder (`~/.lucy-cli`) to store default configurations and file structures for the `init` command. Use the `open` command to access and customize these templates.
|
|
105
119
|
|
|
106
120
|
## Commands & Options
|
|
107
121
|
|
|
108
|
-
Lucy-CLI comes with a
|
|
109
|
-
|
|
110
|
-
### Commands
|
|
111
|
-
|
|
112
|
-
- **`init
|
|
113
|
-
-
|
|
114
|
-
- **`
|
|
115
|
-
- **`
|
|
116
|
-
- **`
|
|
117
|
-
- **`
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
- **`
|
|
122
|
-
- **`
|
|
123
|
-
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
-
|
|
131
|
-
-
|
|
132
|
-
-
|
|
133
|
-
-
|
|
122
|
+
Lucy-CLI comes with a comprehensive set of commands and options. Use `lucy-cli -h` to see a complete overview of all available commands and options.
|
|
123
|
+
|
|
124
|
+
### Main Commands
|
|
125
|
+
|
|
126
|
+
- **`init <type>`**: Initialize a new Lucy project with the specified type
|
|
127
|
+
- **Types**: `velo`, `expo`, `blocks`, `monorepo`, `tauri`, `cargo`, `wix-sdk`
|
|
128
|
+
- **`open`**: Open the Lucy home directory
|
|
129
|
+
- **`task <name>`**: Run a specific task
|
|
130
|
+
- **`wix-sync <action>`**: Run velo-sync actions
|
|
131
|
+
- **`wix-sdk <action>`**: Run Wix SDK actions
|
|
132
|
+
|
|
133
|
+
### Available Tasks
|
|
134
|
+
|
|
135
|
+
- **`dev`**: Start development environment
|
|
136
|
+
- **`build`**: Build the project
|
|
137
|
+
- **`build-prod`**: Build for production
|
|
138
|
+
- **`build-pipeline`**: Build pipeline
|
|
139
|
+
- **`sync-settings`**: Sync settings
|
|
140
|
+
|
|
141
|
+
### Wix Sync Actions
|
|
142
|
+
|
|
143
|
+
- **`sync`**: Synchronize collections
|
|
144
|
+
- **`import`**: Import data from CSV
|
|
145
|
+
- **`init`**: Initialize sync configuration
|
|
146
|
+
- **`is-alive`**: Check if sync is alive
|
|
147
|
+
- **`migrate`**: Migrate data
|
|
148
|
+
- **`export`**: Export data
|
|
149
|
+
|
|
150
|
+
### Project Types
|
|
151
|
+
|
|
152
|
+
- **`velo`**: Wix Velo project
|
|
153
|
+
- **`expo`**: React Native with Expo
|
|
154
|
+
- **`blocks`**: Wix Blocks
|
|
155
|
+
- **`monorepo`**: Monorepo setup
|
|
156
|
+
- **`tauri`**: Tauri desktop app
|
|
157
|
+
- **`cargo`**: Rust project
|
|
158
|
+
- **`wix-sdk`**: Wix SDK setup
|
|
159
|
+
|
|
160
|
+
### Global Options
|
|
161
|
+
|
|
162
|
+
- **`-h, --help`**: Show comprehensive help message with all commands and options
|
|
163
|
+
- **`-v, --version`**: Show version number
|
|
164
|
+
- **`-f, --force`**: Force execution (use with caution)
|
|
134
165
|
|
|
135
166
|
## Examples
|
|
136
167
|
|
|
137
168
|
Here are some example commands to get started with Lucy-CLI:
|
|
138
169
|
|
|
139
170
|
```bash
|
|
140
|
-
#
|
|
141
|
-
lucy-cli
|
|
171
|
+
# Get comprehensive help overview
|
|
172
|
+
lucy-cli -h
|
|
173
|
+
|
|
174
|
+
# Initialize a new Wix Velo project
|
|
175
|
+
lucy-cli init velo
|
|
142
176
|
|
|
143
177
|
# Start the development environment
|
|
144
|
-
lucy-cli dev
|
|
178
|
+
lucy-cli task dev
|
|
145
179
|
|
|
146
180
|
# Synchronize database and settings
|
|
147
|
-
lucy-cli sync
|
|
181
|
+
lucy-cli task sync-settings
|
|
148
182
|
|
|
149
|
-
#
|
|
150
|
-
lucy-cli
|
|
183
|
+
# Run velo-sync import with CSV file
|
|
184
|
+
lucy-cli wix-sync import -i data.csv -c myCollection
|
|
151
185
|
|
|
152
186
|
# Force start the dev environment
|
|
153
|
-
lucy-cli dev -f
|
|
154
|
-
|
|
155
|
-
#
|
|
156
|
-
lucy-cli
|
|
157
|
-
|
|
158
|
-
🦮 Lucy CLI Help
|
|
159
|
-
Usage: lucy-cli <command> [options]
|
|
160
|
-
|
|
161
|
-
Commands:
|
|
162
|
-
🦮 init : Initializes a WIX project to enable full TS support.
|
|
163
|
-
🦮 dev : Starts the development environment. This includes setting up any required services for local development.
|
|
164
|
-
🦮 build-prod : Builds the project in production mode, optimizing files for deployment.
|
|
165
|
-
🦮 prepare : Prepares the project by installing packages & initializing git modules, configured in lucy.json.
|
|
166
|
-
🦮 velo-sync : Synchronizes Wix collections (run `velo-sync -h` for help).
|
|
167
|
-
🦮 install : Installs all Wix and dev npm packages listed in the 'lucy.json' file.
|
|
168
|
-
🦮 fix : Runs a fix command to resolve common issues in development or production settings.
|
|
169
|
-
🦮 docs : Generates documentation for the project.
|
|
170
|
-
🦮 cypress : Starts the cypress test runner.
|
|
171
|
-
🦮 templates : Opens the Lucy CLI templates folder.
|
|
172
|
-
🦮 sync-pkgs : Syncs dependencies from package.json to lucy.json.
|
|
173
|
-
🦮 e2e : Starts the cypress test runner in CI mode. Usage: `e2e <key> <buildId>`
|
|
174
|
-
|
|
175
|
-
Options:
|
|
176
|
-
🦮 -h, help : Displays this help message.
|
|
177
|
-
🦮 -v, version : Displays the current version of Lucy CLI as defined in the project’s package.json.
|
|
178
|
-
🦮 -f, force : Forces specific commands to execute even if they may lead to potential issues.
|
|
179
|
-
Used for functions like deleting obsolete pages or initializing missing components.
|
|
180
|
-
🦮 -l : Locks package versions to those specified in `lucy.json` during installation.
|
|
181
|
-
|
|
182
|
-
Examples:
|
|
183
|
-
🦮 lucy-cli init : Initializes a new Wix project.
|
|
184
|
-
🦮 lucy-cli dev : Starts the development environment.
|
|
185
|
-
🦮 lucy-cli sync : Synchronizes database and settings.
|
|
186
|
-
🦮 lucy-cli install : Installs all Wix and dev npm packages from 'lucy.json'.
|
|
187
|
-
🦮 lucy-cli dev -f : Starts the dev environment with forced settings.
|
|
188
|
-
🦮 lucy-cli install -l : Installs Wix npm packages, respecting locked versions specified in the configuration.
|
|
187
|
+
lucy-cli task dev -f
|
|
188
|
+
|
|
189
|
+
# Check Wix sync status
|
|
190
|
+
lucy-cli wix-sync is-alive
|
|
189
191
|
```
|
|
190
192
|
|
|
193
|
+
## Enhanced Help System
|
|
194
|
+
|
|
195
|
+
Lucy-CLI now provides a comprehensive help overview when you use the `-h` or `--help` flag. This includes:
|
|
196
|
+
|
|
197
|
+
- 📋 Complete list of all available commands
|
|
198
|
+
- 🔧 Available tasks with descriptions
|
|
199
|
+
- 🔄 Wix sync actions with explanations
|
|
200
|
+
- ⚙️ Global options and their usage
|
|
201
|
+
- 📁 Project types for initialization
|
|
202
|
+
- 🦮 Emoji-enhanced interface for better readability
|
|
203
|
+
|
|
204
|
+
The help system dynamically shows all available options based on your current configuration and provides clear examples for each command.
|
|
205
|
+
|
|
191
206
|
If you find Lucy-CLI useful, consider supporting the project:
|
|
192
207
|
[](https://www.buymeacoffee.com/gradlon)
|
package/dist/args.js
CHANGED
|
@@ -70,7 +70,47 @@ export async function get_args() {
|
|
|
70
70
|
.alias('h', 'help')
|
|
71
71
|
.strict()
|
|
72
72
|
.wrap(yargs().terminalWidth())
|
|
73
|
-
.epilogue(
|
|
73
|
+
.epilogue(`
|
|
74
|
+
🦮 Lucy CLI - Complete Command Overview
|
|
75
|
+
|
|
76
|
+
📋 Available Commands:
|
|
77
|
+
init <type> Initialize a new Lucy project (types: ${initTypes.join(', ')})
|
|
78
|
+
open Open the Lucy home directory
|
|
79
|
+
task <name> Run a task (tasks: ${taskNames.join(', ')})
|
|
80
|
+
wix-sync <action> Run velo-sync actions (actions: ${syncActions.join(', ')})
|
|
81
|
+
wix-sdk <action> Run Wix SDK actions
|
|
82
|
+
|
|
83
|
+
🔧 Available Tasks:
|
|
84
|
+
dev Start development environment
|
|
85
|
+
build Build the project
|
|
86
|
+
build-prod Build for production
|
|
87
|
+
build-pipeline Build pipeline
|
|
88
|
+
sync-settings Sync settings
|
|
89
|
+
|
|
90
|
+
🔄 Wix Sync Actions:
|
|
91
|
+
sync Synchronize collections
|
|
92
|
+
import Import data from CSV
|
|
93
|
+
init Initialize sync configuration
|
|
94
|
+
is-alive Check if sync is alive
|
|
95
|
+
migrate Migrate data
|
|
96
|
+
export Export data
|
|
97
|
+
|
|
98
|
+
⚙️ Global Options:
|
|
99
|
+
-h, --help Show this help message
|
|
100
|
+
-v, --version Show version number
|
|
101
|
+
-f, --force Force execution (use with caution)
|
|
102
|
+
|
|
103
|
+
📁 Project Types:
|
|
104
|
+
velo Wix Velo project
|
|
105
|
+
expo React Native with Expo
|
|
106
|
+
blocks Wix Blocks
|
|
107
|
+
monorepo Monorepo setup
|
|
108
|
+
tauri Tauri desktop app
|
|
109
|
+
cargo Rust project
|
|
110
|
+
wix-sdk Wix SDK setup
|
|
111
|
+
|
|
112
|
+
For more information, visit https://github.com/Sunnyside-UP-GmbH/lucy-cli
|
|
113
|
+
`)
|
|
74
114
|
.parseAsync();
|
|
75
115
|
// The cast is now safer with the defined interface.
|
|
76
116
|
return argv;
|
package/dist/args.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"args.js","sourceRoot":"","sources":["../src/args.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,EAAE,OAAO,EAAE,MAAM,eAAe,CAAC;AACxC,OAAO,EAAE,SAAS,EAAY,SAAS,EAAE,WAAW,EAAE,MAAM,oBAAoB,CAAC;AACjF,OAAO,EAAE,aAAa,EAAE,MAAM,aAAa,CAAC;AAE5C,MAAM,OAAO,GAAG,aAAa,CAAC,MAAM,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC;AAC/C,MAAM,GAAG,GAAG,OAAO,CAAC,iBAAiB,CAAC,CAAC;AAEvC,MAAM,CAAC,KAAK,UAAU,QAAQ;IAC1B,MAAM,IAAI,GAAG,MAAM,KAAK,CAAC,OAAO,CAAC,OAAO,CAAC,IAAI,CAAC,CAAC;SAC1C,KAAK,CAAC,+BAA+B,CAAC;SACtC,OAAO,CAAC,iBAAiB,EAAE,+BAA+B,EAAE,CAAC,KAAK,EAAE,EAAE;QACnE,OAAO,KAAK,CAAC,UAAU,CAAC,UAAU,EAAE;YAChC,QAAQ,EAAE,mCAAmC;YAC7C,OAAO,EAAE,SAAS;YAClB,YAAY,EAAE,IAAI;SACrB,CAAC,CAAA;IACN,CAAC,CAAC,CAAC,MAAM,CAAC,OAAO,EAAE;QACf,KAAK,EAAE,GAAG;QACV,IAAI,EAAE,SAAS;QACf,WAAW,EAAE,gBAAgB;KAChC,CAAC;SACD,OAAO,CAAC,MAAM,EAAE,8BAA8B,CAAC;SAC/C,OAAO,CAAC,kBAAkB,EAAE,YAAY,EAAE,CAAC,KAAK,EAAE,EAAE;QACjD,OAAO,KAAK,CAAC,UAAU,CAAC,WAAW,EAAE;YACjC,QAAQ,EAAE,iBA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C,GAAG,EAAE,SAAS,CAAC;SACrB,IAAI,EAAE;SACN,KAAK,CAAC,GAAG,EAAE,MAAM,CAAC;SAClB,MAAM,EAAE;SACR,IAAI,CAAC,KAAK,EAAE,CAAC,aAAa,EAAE,CAAC;SAC7B,QAAQ,CAAC;;;;6DAI2C,SAAS,CAAC,IAAI,CAAC,IAAI,CAAC;;0CAEvC,SAAS,CAAC,IAAI,CAAC,IAAI,CAAC;uDACP,WAAW,CAAC,IAAI,CAAC,IAAI,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;SAiCpE,CAAC;SACD,UAAU,EAAE,CAAC;IAElB,oDAAoD;IAEpD,OAAO,IAAgB,CAAC;AAC5B,CAAC"}
|
package/dist/commands/exec.d.ts
CHANGED
|
@@ -3,5 +3,5 @@ import { Config } from "../config.js";
|
|
|
3
3
|
import { FileSystem } from "@effect/platform";
|
|
4
4
|
import { AppError } from "../error.js";
|
|
5
5
|
export declare const execCommand: Effect.Effect<void, import("@effect/platform/Error").PlatformError, Config | import("@effect/platform/CommandExecutor").CommandExecutor>;
|
|
6
|
-
export declare const open: Effect.Effect<void, import("@effect/platform/Error").PlatformError, Config | import("@effect/platform/CommandExecutor").CommandExecutor
|
|
7
|
-
export declare const
|
|
6
|
+
export declare const open: Effect.Effect<void, import("@effect/platform/Error").PlatformError, Config | FileSystem.FileSystem | import("@effect/platform/CommandExecutor").CommandExecutor>;
|
|
7
|
+
export declare const openEditor: Effect.Effect<void, AppError | import("effect/ParseResult").ParseError | import("@effect/platform/Error").PlatformError, Config | import("@effect/platform/CommandExecutor").CommandExecutor>;
|
package/dist/commands/exec.js
CHANGED
|
@@ -5,6 +5,7 @@ import { logger } from "../utils/logger.js";
|
|
|
5
5
|
import { FileSystem } from "@effect/platform";
|
|
6
6
|
import Enquirer from "enquirer";
|
|
7
7
|
import { AppError } from "../error.js";
|
|
8
|
+
import { editors } from "../schemas/index.js";
|
|
8
9
|
export const execCommand = Effect.gen(function* () {
|
|
9
10
|
const config = yield* Config;
|
|
10
11
|
const cmds = config.config.lucySettings.additionalCommands ?? [];
|
|
@@ -39,18 +40,15 @@ export const open = Effect.scoped(Effect.gen(function* () {
|
|
|
39
40
|
command.pipe().pipe(Command.stdout("inherit"), Command.stderr("inherit"), Command.exitCode);
|
|
40
41
|
yield* command.pipe().pipe(Command.stdout("inherit"), Command.stderr("inherit"), Command.exitCode);
|
|
41
42
|
}));
|
|
42
|
-
export const
|
|
43
|
+
export const openEditor = Effect.gen(function* () {
|
|
43
44
|
const config = yield* Config;
|
|
44
|
-
const
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
type: 'confirm',
|
|
52
|
-
name: 'openVSCode',
|
|
53
|
-
message: `Do you want to open the project in VSCode?`,
|
|
45
|
+
const editorQuestion = new Enquirer();
|
|
46
|
+
const openEditorQuestion = yield* Effect.tryPromise({
|
|
47
|
+
try: () => editorQuestion.prompt({
|
|
48
|
+
type: 'select',
|
|
49
|
+
name: 'openEditor',
|
|
50
|
+
message: `Do you want to open the project in a supported editor?`,
|
|
51
|
+
choices: [...editors, 'No'],
|
|
54
52
|
}),
|
|
55
53
|
catch: (e) => {
|
|
56
54
|
return new AppError({
|
|
@@ -59,8 +57,12 @@ export const openVSCode = Effect.gen(function* () {
|
|
|
59
57
|
});
|
|
60
58
|
}
|
|
61
59
|
});
|
|
62
|
-
const choice = yield* Schema.decodeUnknown(Schema.Struct({
|
|
63
|
-
|
|
60
|
+
const choice = yield* Schema.decodeUnknown(Schema.Struct({ openEditor: Schema.Literal(...editors, 'No') }))(openEditorQuestion);
|
|
61
|
+
const open = Command.make(choice.openEditor, config.config.cwd).pipe(Command.stdout("inherit"), // Stream stdout to process.stdout
|
|
62
|
+
Command.stderr("inherit"), // Stream stderr to process.stderr
|
|
63
|
+
Command.exitCode // Get the exit code
|
|
64
|
+
);
|
|
65
|
+
if (choice.openEditor !== 'No') {
|
|
64
66
|
yield* open;
|
|
65
67
|
}
|
|
66
68
|
});
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"exec.js","sourceRoot":"","sources":["../../src/commands/exec.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,MAAM,EAAE,MAAM,EAAE,MAAM,cAAc,CAAC;AAC9C,OAAO,EAAE,MAAM,EAAE,MAAM,cAAc,CAAC;AACtC,OAAO,EAAE,OAAO,EAAE,MAAM,wBAAwB,CAAC;AACjD,OAAO,EAAE,MAAM,EAAE,MAAM,oBAAoB,CAAC;AAC5C,OAAO,EAAE,UAAU,EAAE,MAAM,kBAAkB,CAAA;AAC7C,OAAO,QAAQ,MAAM,UAAU,CAAC;AAChC,OAAO,EAAE,QAAQ,EAAE,MAAM,aAAa,CAAC;
|
|
1
|
+
{"version":3,"file":"exec.js","sourceRoot":"","sources":["../../src/commands/exec.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,MAAM,EAAE,MAAM,EAAE,MAAM,cAAc,CAAC;AAC9C,OAAO,EAAE,MAAM,EAAE,MAAM,cAAc,CAAC;AACtC,OAAO,EAAE,OAAO,EAAE,MAAM,wBAAwB,CAAC;AACjD,OAAO,EAAE,MAAM,EAAE,MAAM,oBAAoB,CAAC;AAC5C,OAAO,EAAE,UAAU,EAAE,MAAM,kBAAkB,CAAA;AAC7C,OAAO,QAAQ,MAAM,UAAU,CAAC;AAChC,OAAO,EAAE,QAAQ,EAAE,MAAM,aAAa,CAAC;AACvC,OAAO,EAAE,OAAO,EAAE,MAAM,qBAAqB,CAAC;AAE9C,MAAM,CAAC,MAAM,WAAW,GAAG,MAAM,CAAC,GAAG,CAAC,QAAQ,CAAC;IAC3C,MAAM,MAAM,GAAG,KAAK,CAAC,CAAC,MAAM,CAAC;IAC7B,MAAM,IAAI,GAAG,MAAM,CAAC,MAAM,CAAC,YAAY,CAAC,kBAAkB,IAAI,EAAE,CAAC;IACjE,MAAM,CAAC,IAAI,CAAC,kCAAkC,EAAE,IAAI,CAAC,C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IAAI,CAAC,EAAE,CAAC,CAAC,CAAC,kBAAkB,CAAC,CAAC;IAEhI,MAAM,IAAI,GAAG,OAAO,CAAC,IAAI,CACrB,MAAM,CAAC,UAAU,EACjB,MAAM,CAAC,MAAM,CAAC,GAAG,CAChB,CAAC,IAAI,CACN,OAAO,CAAC,MAAM,CAAC,SAAS,CAAC,EAAE,kCAAkC;IAC7D,OAAO,CAAC,MAAM,CAAC,SAAS,CAAC,EAAE,kCAAkC;IAC7D,OAAO,CAAC,QAAQ,CAAC,oBAAoB;KACxC,CAAA;IACD,IAAI,MAAM,CAAC,UAAU,KAAK,IAAI,EAAE,CAAC;QAC7B,KAAK,CAAC,CAAC,IAAI,CAAA;IACf,CAAC;AACL,CAAC,CAAC,CAAA"}
|
package/dist/commands/home.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
import { Effect } from "effect/index";
|
|
2
2
|
import { Config } from "../config.js";
|
|
3
|
-
import { FileSystem } from "@effect/platform";
|
|
4
|
-
export declare const createLucyHome: () => Effect.Effect<void,
|
|
3
|
+
import { FileSystem, Path } from "@effect/platform";
|
|
4
|
+
export declare const createLucyHome: () => Effect.Effect<void, any, Config | FileSystem.FileSystem | Path.Path>;
|
package/dist/commands/home.js
CHANGED
|
@@ -1,18 +1,41 @@
|
|
|
1
1
|
import { Effect } from "effect/index";
|
|
2
2
|
import { Config } from "../config.js";
|
|
3
|
-
import { FileSystem } from "@effect/platform";
|
|
3
|
+
import { FileSystem, Path } from "@effect/platform";
|
|
4
4
|
import { logger, orange } from "../utils/logger.js";
|
|
5
5
|
import path from 'path';
|
|
6
6
|
export const createLucyHome = () => {
|
|
7
7
|
return Effect.gen(function* () {
|
|
8
8
|
const config = yield* Config;
|
|
9
9
|
const fs = yield* FileSystem.FileSystem;
|
|
10
|
+
const p = yield* Path.Path;
|
|
10
11
|
if (!(yield* fs.exists(config.config.lucyHome))) {
|
|
11
12
|
logger.action(`Creating Lucy home directory at ${orange(config.config.lucyHome)}`);
|
|
12
13
|
yield* fs.makeDirectory(config.config.lucyHome, { recursive: true });
|
|
13
14
|
}
|
|
14
15
|
const templateFiles = yield* fs.readDirectory(config.config.filesFolder);
|
|
15
|
-
|
|
16
|
+
const shouldExclude = (relativePath) => {
|
|
17
|
+
const segments = relativePath.split(/[/\\]/);
|
|
18
|
+
return segments.includes("node_modules") || segments.includes("Pods");
|
|
19
|
+
};
|
|
20
|
+
const copyDirFiltered = (src, dest, base) => Effect.gen(function* () {
|
|
21
|
+
const entries = yield* fs.readDirectory(src);
|
|
22
|
+
yield* fs.makeDirectory(dest, { recursive: true });
|
|
23
|
+
yield* Effect.forEach(entries, (entry) => Effect.gen(function* () {
|
|
24
|
+
const from = p.join(src, entry);
|
|
25
|
+
const to = p.join(dest, entry);
|
|
26
|
+
const rel = base ? p.relative(base, from) : entry;
|
|
27
|
+
if (shouldExclude(rel)) {
|
|
28
|
+
return;
|
|
29
|
+
}
|
|
30
|
+
const stat = yield* fs.stat(from);
|
|
31
|
+
if (stat.type === "Directory") {
|
|
32
|
+
yield* copyDirFiltered(from, to, base ?? src);
|
|
33
|
+
return;
|
|
34
|
+
}
|
|
35
|
+
yield* fs.copyFile(from, to);
|
|
36
|
+
}), { discard: true });
|
|
37
|
+
});
|
|
38
|
+
yield* Effect.forEach(templateFiles, (file) => copyDirFiltered(path.join(config.config.filesFolder, file), path.join(config.config.lucyHome, file)), { discard: true });
|
|
16
39
|
});
|
|
17
40
|
};
|
|
18
41
|
//# sourceMappingURL=home.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"home.js","sourceRoot":"","sources":["../../src/commands/home.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,MAAM,EAAE,MAAM,cAAc,CAAC;AACtC,OAAO,EAAE,MAAM,EAAE,MAAM,cAAc,CAAC;AACtC,OAAO,EAAE,UAAU,EAAE,MAAM,kBAAkB,CAAA;
|
|
1
|
+
{"version":3,"file":"home.js","sourceRoot":"","sources":["../../src/commands/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E,CACpB,CAAA;QACL,CAAC,CAAC,CAAA;QAEN,KAAK,CAAC,CAAC,MAAM,CAAC,OAAO,CACjB,aAAa,EACb,CAAC,IAAI,EAAE,EAAE,CAAC,eAAe,CAAC,IAAI,CAAC,IAAI,CAAC,MAAM,CAAC,MAAM,CAAC,WAAW,EAAE,IAAI,CAAC,EAAE,IAAI,CAAC,IAAI,CAAC,MAAM,CAAC,MAAM,CAAC,QAAQ,EAAE,IAAI,CAAC,CAAC,EAC9G,EAAE,OAAO,EAAE,IAAI,EAAE,CACpB,CAAA;IACL,CAAC,CAAC,CAAC;AACP,CAAC,CAAA"}
|
|
@@ -4,5 +4,6 @@ import { CommandExecutor } from "@effect/platform/CommandExecutor";
|
|
|
4
4
|
import { PlatformError } from "@effect/platform/Error";
|
|
5
5
|
export declare const installPackages: (workspace?: boolean) => Effect.Effect<void, PlatformError, Config | CommandExecutor>;
|
|
6
6
|
export declare const runInstall: Effect.Effect<void, PlatformError, Config | CommandExecutor>;
|
|
7
|
+
export declare const yarnSetVersion: Effect.Effect<void, PlatformError, CommandExecutor>;
|
|
7
8
|
export declare const installVeloPackages: Effect.Effect<void, PlatformError, Config | CommandExecutor>;
|
|
8
9
|
export declare const approveBuilds: Effect.Effect<void, PlatformError, Config | CommandExecutor>;
|
package/dist/commands/install.js
CHANGED
|
@@ -77,18 +77,12 @@ export const runInstall = Effect.gen(function* () {
|
|
|
77
77
|
);
|
|
78
78
|
yield* install;
|
|
79
79
|
});
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
//
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
// ).pipe(
|
|
87
|
-
// Command.stdout("inherit"), // Stream stdout to process.stdout
|
|
88
|
-
// Command.exitCode // Get the exit code
|
|
89
|
-
// )
|
|
90
|
-
// yield* yarnDev;
|
|
91
|
-
// })
|
|
80
|
+
export const yarnSetVersion = Effect.gen(function* () {
|
|
81
|
+
const set = Command.make("yarn", "set", "version", "berry").pipe(Command.stdout("inherit"), // Stream stdout to process.stdout
|
|
82
|
+
Command.exitCode // Get the exit code
|
|
83
|
+
);
|
|
84
|
+
yield* set;
|
|
85
|
+
});
|
|
92
86
|
export const installVeloPackages = Effect.gen(function* () {
|
|
93
87
|
const config = yield* Config;
|
|
94
88
|
const simpleSchedule = Schedule.tapOutput(Schedule.fromDelays(50, 100, 200, 400, 800, 1600, 3200), (n) => Effect.succeed(logger.warning(`Failed to install WIX package. Retrying...`)));
|
|
@@ -129,10 +123,29 @@ export const installVeloPackages = Effect.gen(function* () {
|
|
|
129
123
|
}
|
|
130
124
|
devPkgs.push(key);
|
|
131
125
|
}
|
|
132
|
-
const
|
|
126
|
+
const manager = config.config.lucySettings.packageManager;
|
|
127
|
+
function pkgMgrParamsInstall() {
|
|
128
|
+
if (manager === "npm") {
|
|
129
|
+
return ["install"];
|
|
130
|
+
}
|
|
131
|
+
if (manager === "pnpm") {
|
|
132
|
+
return ["install"];
|
|
133
|
+
}
|
|
134
|
+
return ["add"];
|
|
135
|
+
}
|
|
136
|
+
function pkgMgrParamsInstallDev() {
|
|
137
|
+
if (manager === "npm") {
|
|
138
|
+
return ["install", "-D"];
|
|
139
|
+
}
|
|
140
|
+
if (manager === "pnpm") {
|
|
141
|
+
return ["install", "-D"];
|
|
142
|
+
}
|
|
143
|
+
return ["add", "-D"];
|
|
144
|
+
}
|
|
145
|
+
const install = Command.make(manager, ...pkgMgrParamsInstall(), ...pkgs).pipe(Command.stdout("inherit"), // Stream stdout to process.stdout
|
|
133
146
|
Command.exitCode // Get the exit code
|
|
134
147
|
);
|
|
135
|
-
const
|
|
148
|
+
const installDev = Command.make(manager, ...pkgMgrParamsInstallDev(), ...devPkgs).pipe(Command.stdout("inherit"), // Stream stdout to process.stdout
|
|
136
149
|
Command.exitCode // Get the exit code
|
|
137
150
|
);
|
|
138
151
|
logger.info("Installing dependencies with wix...");
|
|
@@ -141,11 +154,11 @@ export const installVeloPackages = Effect.gen(function* () {
|
|
|
141
154
|
return logger.error("Failed to install WIX dependencies. Please check the error message above.");
|
|
142
155
|
}
|
|
143
156
|
logger.info("Installing dependencies");
|
|
144
|
-
if ((yield*
|
|
157
|
+
if ((yield* install) !== 0) {
|
|
145
158
|
return logger.error("Failed to install dependencies. Please check the error message above.");
|
|
146
159
|
}
|
|
147
160
|
logger.info("Installing dev dependencies");
|
|
148
|
-
if ((yield*
|
|
161
|
+
if ((yield* installDev) !== 0) {
|
|
149
162
|
return logger.error("Failed to install dev dependencies. Please check the error message above.");
|
|
150
163
|
}
|
|
151
164
|
});
|