mirror of
https://github.com/Memo-2023/mana-monorepo.git
synced 2026-05-14 23:01:09 +02:00
Two halves of the same "why is sync inactive in dev" fix: - package.json: new dev:credits script and mana-credits added to the dev:mana:servers concurrently group. The service was never started by pnpm dev:mana:all, so the frontend's GET /api/v1/sync/status failed, syncBilling.load() caught the error and defaulted to inactive — while mana-sync (Go) was actually fail-open on the billing check, making the UI indicator lie about the backend state. - scripts/dev/setup-dev-user.sh: after the existing email-verify + tier-lift UPDATE, upsert a row into credits.sync_subscriptions with is_gifted=true. Mirrors what POST /api/v1/admin/sync/:id/gift would do, so every new dev user gets Cloud Sync from the first login without a separate admin call. The credits schema lives inside mana_platform, so no new database needed — just a second statement in the same psql heredoc. Existing dev users (tills95, tilljkb, rajiehq) were backfilled manually with the same INSERT … ON CONFLICT DO UPDATE once; future runs of setup-dev-user.sh stay idempotent. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com> |
||
|---|---|---|
| .. | ||
| setup-dev-user.sh | ||