fix(workflows): support all repos in agent doc sync

This commit is contained in:
saravanakumardb1 2026-03-24 16:10:41 -07:00
parent e8d145a130
commit 911539f228

View File

@ -131,6 +131,59 @@ set_meta() {
LINT3="cd mobile && npm run typecheck 2>&1 | tail -10"
AIDER_READ2="docs/ROADMAP.md"
;;
learning_ai_trails)
NAME="ActionTrail"
ID="actiontrail"
TAGLINE="AI activity oversight platform"
STACK="Next.js 16 (web) + Fastify 5 (backend) + TypeScript ESM"
BUILD_VFY="cd backend && npm test && npm run typecheck && cd ../sdk && npm test && npm run typecheck && cd ../web && npm run typecheck"
LINT1="cd backend && npm test 2>&1 | tail -10"
LINT2="cd backend && npm run typecheck 2>&1 | tail -10"
LINT3="cd sdk && npm run typecheck 2>&1 | tail -10"
AIDER_READ2="docs/roadmap.md"
;;
learning_ai_local_memory_gpt)
NAME="Local Memory GPT"
ID="localmemgpt"
TAGLINE="Local-first AI chat with persistent memory, RAG, and multi-model compare"
STACK="Fastify 5 + TypeScript ESM (backend) + Next.js 16 (web) + SQLite + Ollama"
BUILD_VFY="cd backend && npm test && npm run typecheck && npm run build && cd ../web && npm run typecheck && npm run build"
LINT1="cd backend && npm test 2>&1 | tail -10"
LINT2="cd backend && npm run typecheck 2>&1 | tail -10"
LINT3="cd web && npm run typecheck 2>&1 | tail -10"
AIDER_READ2="README.md"
;;
learning_ai_smart_auth)
NAME="ByteLyst SmartAuth"
ID="smartauth"
TAGLINE="Unified authentication and identity platform"
STACK="Design/docs repo extending platform-service auth, shared auth packages, and native SDKs"
BUILD_VFY="cd ../learning_ai_common_plat && pnpm build && pnpm test && pnpm typecheck"
LINT1="cd ../learning_ai_common_plat && pnpm build 2>&1 | tail -10"
LINT2="cd ../learning_ai_common_plat && pnpm test 2>&1 | tail -10"
LINT3="cd ../learning_ai_common_plat && pnpm typecheck 2>&1 | tail -10"
AIDER_READ2="README.md"
;;
learning_ai_auth_app)
NAME="ByteLyst Auth"
ID="smartauth"
TAGLINE="Standalone companion app for ByteLyst authentication"
STACK="SwiftUI (iOS/Watch) + Jetpack Compose (Android) — no separate backend"
BUILD_VFY="cd ios && xcodegen generate && xcodebuild -scheme ByteLystAuth -sdk iphonesimulator build && cd ../android && ./gradlew :app:assembleDebug"
LINT1="cd ios && xcodegen generate >/dev/null 2>&1 && xcodebuild -scheme ByteLystAuth -sdk iphonesimulator build 2>&1 | tail -20"
LINT2="cd android && ./gradlew :app:assembleDebug 2>&1 | tail -20"
AIDER_READ2="README.md"
;;
learning_ai_productivity_web)
NAME="Productivity Web"
ID="(internal)"
TAGLINE="Internal Next.js productivity tools portal"
STACK="Next.js 15 + React 19 + TailwindCSS"
BUILD_VFY="npm run typecheck && npm run build"
LINT1="npm run typecheck 2>&1 | tail -10"
LINT2="npm run build 2>&1 | tail -10"
AIDER_READ2="README.md"
;;
*)
warn "Unknown repo: $1 — skipping"
return 1
@ -218,6 +271,41 @@ repo_rules() {
echo "- Mobile engine logic in mobile/src/lib/ — pure TS, no React Native imports"
echo "- Every Cosmos document MUST include productId: \"flowmonk\""
;;
learning_ai_trails)
echo "- Backend modules follow types.ts → repository.ts → routes.ts"
echo "- Use req.log / app.log — never console.log"
echo "- Web engine logic in web/src/lib/ — pure TS, no React imports"
echo "- Every Cosmos document MUST include productId: \"actiontrail\""
echo "- Use productConfig.productId — never hardcode product IDs"
;;
learning_ai_local_memory_gpt)
echo "- Backend modules follow types.ts → repository.ts → routes.ts"
echo "- Use req.log / app.log — never console.log"
echo "- ESM everywhere: \"type\": \"module\", .js extensions in imports"
echo "- Theme tokens use --lmg-* CSS custom properties"
echo "- Use productConfig.productId — never hardcode localmemgpt"
;;
learning_ai_smart_auth)
echo "- SmartAuth is NOT a separate service — it extends platform-service"
echo "- Auth work belongs in platform-service/src/modules/auth/ and shared auth packages"
echo "- Use req.log / app.log — never console.log in implementation repos"
echo "- Every Cosmos document MUST include a productId field"
echo "- Never hardcode OAuth client IDs or secrets"
;;
learning_ai_auth_app)
echo "- Use BLAuthClient from platform SDKs — never reimplement auth logic"
echo "- Use BLAuthUI views — never build custom auth UI"
echo "- All logging via os.Logger in Swift — never print()"
echo "- Theme via BLAuthUIConfig (iOS) / MaterialTheme (Android)"
echo "- Never create a separate backend — app talks to platform-service"
;;
learning_ai_productivity_web)
echo "- App Router pages live in src/app/"
echo "- Reusable UI lives in src/components/"
echo "- Shared utilities live in src/lib/"
echo "- Keep UI changes thin and tool-registry-driven where possible"
echo "- Avoid inventing APIs or hidden backend contracts"
;;
esac
}
@ -290,6 +378,39 @@ repo_paths() {
echo "- mobile/src/lib/ — Pure TS engine modules"
echo "- mobile/src/app/ — Expo Router screens"
;;
learning_ai_trails)
echo "- backend/src/lib/ — shared backend wiring, events, RBAC, risk scoring"
echo "- backend/src/modules/ — actions, alerts, agents, approvals, traces, connectors, reverts"
echo "- web/src/lib/ — typed API clients and product config"
echo "- web/src/components/ — React UI components"
echo "- sdk/src/ — ActionTrail SDK and middleware"
;;
learning_ai_local_memory_gpt)
echo "- backend/src/lib/ — config, sqlite, ollama, llm, SSE helpers"
echo "- backend/src/modules/ — conversations, messages, chat, models, documents, search, compare"
echo "- web/src/lib/ — typed API client, store, config, telemetry"
echo "- web/src/components/ — chat/search/documents/settings UI"
echo "- shared/product.json — canonical product identity"
;;
learning_ai_smart_auth)
echo "- docs/ — PRD, roadmap, coding agent prompts"
echo "- shared/product.json — canonical product identity"
echo "- implementation happens in ../learning_ai_common_plat/services/platform-service/src/modules/auth/"
echo "- implementation happens in ../learning_ai_common_plat/packages/auth* and native SDKs"
;;
learning_ai_auth_app)
echo "- ios/ByteLystAuth/App/ — entry point + ContentView"
echo "- ios/ByteLystAuth/Screens/ — dashboard, approvals, TOTP, devices, settings"
echo "- android/app/src/main/kotlin/com/bytelyst/auth/ — Compose screens + navigation"
echo "- shared/product.json — canonical product identity"
echo "- ios/project.yml and android/ build files — native project wiring"
;;
learning_ai_productivity_web)
echo "- src/app/ — App Router pages and routes"
echo "- src/components/ — Navbar and tool cards"
echo "- src/lib/ — utility and tool registry helpers"
echo "- next.config.ts, tailwind.config.ts — web app configuration"
;;
esac
}
@ -571,10 +692,13 @@ for REPO in "${REPOS[@]}"; do
.editorconfig .cursorrules .windsurfrules .clinerules \
.aider.conf.yml CLAUDE.md .github/copilot-instructions.md \
2>/dev/null || true
git -C "$REPO_DIR" commit -m "chore(docs): regenerate AI agent config files" \
--no-verify 2>/dev/null || true
ok "Committed changes in ${REPO}"
CHANGED_REPOS+=("$REPO")
if git -C "$REPO_DIR" commit -m "chore(docs): regenerate AI agent config files" \
--no-verify 2>/dev/null; then
ok "Committed changes in ${REPO}"
CHANGED_REPOS+=("$REPO")
else
warn "Detected changes in ${REPO}, but no commit was created"
fi
else
info "No changes in ${REPO}"
fi