Commit Graph

4 Commits

Author SHA1 Message Date
2c9dc1870d chore(platform): document script CLI output
What changed:
- Added explicit no-console policy for platform-service CLI/codegen scripts.
- Replaced the remaining migrate-referrals catch any with unknown narrowing.
- Added a TODO for making migrate-referrals --help independent of service env loading.

Warning impact:
- Platform script lint warnings: 78 -> 0.
- Workspace lint: 90 -> 12 warnings.

Verification:
- pnpm --filter @lysnrai/platform-service build
- pnpm --filter @lysnrai/platform-service exec eslint scripts --ext .ts
- pnpm lint

Note:
- migrate-referrals --help still requires service env due eager config import; TODO added for a follow-up behavior-safe refactor.
2026-05-04 16:45:42 -07:00
saravanakumardb1
16dc1c4a79 feat(platform-service): overhaul module generator with auto-patching
- Rewrote gen-module.ts to match actual codebase patterns
- Repository uses getRegisteredContainer from @bytelyst/cosmos
- Routes use req.jwtPayload?.sub for auth (not req.user)
- Routes register with explicit /name paths under /api prefix
- Auto-patches cosmos-init.ts with container definition
- Auto-patches server.ts with import + route registration
- Proper parenthesis-aware field splitter for enum(a,b,c)
- Test template generates per-field validation tests
- Checks for existing module directory before overwriting
- Pascal/camel case helpers handle hyphenated module names
- Dry-run shows auto-patch previews
2026-03-19 19:52:06 -07:00
saravanakumardb1
fcbae17866 feat(platform-service): implement P0-1 - Module generator script (pnpm gen:module)
- Add gen-module.ts with full CLI interface
- Generate types.ts, repository.ts, routes.ts, and test.ts
- Support field types: string, number, boolean, date, datetime, enum, string[], number[]
- Add --dry-run flag for preview
- Register script in package.json
2026-03-03 10:05:55 -08:00
saravanakumardb1
3e05260a6f feat(marketplace): generic template marketplace with listings, reviews, installs, certification 2026-03-02 10:02:54 -08:00