Add host-first environment contracts (Local vs CI vs Prod), deps-only compose, and the Profile → Portrait → deep-access mock payment slice with device identity and auto-migrate on API startup. Co-authored-by: Cursor <cursoragent@cursor.com>
1.1 KiB
1.1 KiB
CONTRIBUTING
AI-first
环境分流(必读):
.ai/environment.md— Local / CI / Prod 分离.ai/development.md— 本地本机 Go + Vite.ai/docker.md— Docker 只做依赖与部署.ai/deployment.md— 生产不可变镜像
Local(默认)
# 1) 依赖服务 only
docker compose -f docker-compose.dev.yml up -d
# 2) API — 本机 Go(不要 docker build api)
export GOPROXY=https://goproxy.cn,direct # 如需要
cd apps/api && go run ./cmd/server
# 可选热更: air
# 3) H5 — 本机 Vite(不要 docker build web)
npm install && npm run dev:h5
Git
Trunk-Based;Conventional Commits(feat: / fix: / docs: …)。
PR
- 一个功能点。
- API 变更同步
proto/openapi.yaml。 - 勿把「本地必须全量 compose 起 api/web」写进新文档。