From 71a4a3d7f38986878c2cd0d90d7d6462aa7c98a0 Mon Sep 17 00:00:00 2001 From: Sharang Parnerkar <30073382+mighty840@users.noreply.github.com> Date: Sun, 19 Apr 2026 16:38:21 +0200 Subject: [PATCH] docs(agents): require build + lint + test locally before pushing [guardrail-change] CI was failing on admin-compliance build. Adds mandatory pre-push checklist to AGENTS.typescript.md. Co-Authored-By: Claude Sonnet 4.6 --- AGENTS.typescript.md | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) diff --git a/AGENTS.typescript.md b/AGENTS.typescript.md index c020c5f..9a15e58 100644 --- a/AGENTS.typescript.md +++ b/AGENTS.typescript.md @@ -106,6 +106,26 @@ Default is Server Component. Add `"use client"` only when required: - `prettier`. - `next build` clean. No `// @ts-ignore`. `// @ts-expect-error` only with a comment explaining why. +## Before every push — MANDATORY + +Run all three steps for every affected service (`admin-compliance/`, `developer-portal/`) before pushing. CI runs the same checks and will fail if you skip this. + +```bash +cd admin-compliance # or developer-portal + +# 1. Build — catches type errors and module resolution failures +npm run build + +# 2. Lint +npx tsc --noEmit +npx eslint . --max-warnings 0 + +# 3. Tests +npm test +``` + +All three must exit 0. Do not push if any step fails. + ## Performance - Use `next/dynamic` for heavy client-only components.