# =========================================================================
# AI Project Template — .gitignore
# Trim or extend per project, but treat the secrets/build/data sections as
# load-bearing: removing them is what causes accidental credential commits.
# =========================================================================

# --- Secrets & local config ---
.env
.env.local
.env.*.local
.env.development
.env.staging
.env.production
.env.backup.*

# --- AWS credentials ---
.aws/

# --- Node / Next.js (site) ---
# Unanchored on purpose: `site/node_modules/` alone left a ROOT-level
# node_modules/ tracked, and running vitest from the repo root (rather than from
# site/) creates one — `node_modules/.vite/vitest/**/results.json` reached
# `development` in #320 through a `git add -A`, passing review and CI without
# anything failing. A rule that covers the path someone already hit is not a rule.
# ⚠️ NO TRAILING SLASH, and that is load-bearing too. `node_modules/` matches
# DIRECTORIES ONLY, so a SYMLINKED node_modules is not ignored and `git add -A`
# stages the link itself — an absolute path that resolves for nobody else (gh
# #756). Symlinking it is the documented way to share one 733 MB install across
# git worktrees on a full disk, so the ignore rule and the disk guidance
# disagreed silently. Verified by controlled test: with `node_modules/`,
# `git add -A` reports `A  node_modules`; without the slash it reports nothing.
node_modules
site/node_modules
site/.next/
site/.next-*/
site/out/
site/public/assets/*
!site/public/assets/.gitkeep
*.tsbuildinfo

# --- Python (api) ---
__pycache__/
*.pyc
*.pyo
*.pyd
.Python
.venv/
venv/
env/
.pytest_cache/
.mypy_cache/
.ruff_cache/
*.egg-info/
dist/
build/

# --- App database / local data ---
*.db
*.sqlite
*.sqlite3
app-db/data/
data/

# --- Docker / LocalStack ---
ops/localstack/volume/
localstack-volume/

# --- Langfuse local artifacts ---
ops/langfuse/storage/
ops/langfuse/turbo-cache/

# --- CloudFormation outputs / task defs ---
task-def*.json
new-task-def*.json
task_def_out.json
cloudformation-outputs/
backups/cloudformation-*.yaml
scripts/aws/*.log

# --- OS / editor noise ---
.DS_Store
Thumbs.db
.vscode/
.idea/
*.swp
*:Zone.Identifier

# --- Cursor / Claude local settings (keep settings.json, drop settings.local.json) ---
.cursor/*
.claude/settings.local.json
.claude/scheduled_tasks.lock

# --- Test outputs ---
coverage/
.coverage
htmlcov/
junit.xml

# --- Tooling caches ---
.next/
.turbo/
.playwright-mcp/

# --- Manual-testing artifacts (screenshots, diff captures, etc.) ---
# These accumulate at repo-root during ad-hoc UI testing and shouldn't
# land in commits. If you need to keep a screenshot, move it under
# docs/ or supplemental/ with an explicit name.
/*.png
/*.jpg
/*.jpeg

# Playwright snapshot artifacts
*.playwright-mcp/
editor-*.md
builder*.md

# onboarding stress-test scratch harness
_stress/
api/_stress/

# Local user-testing artifacts (reports, screenshots, transcripts) — not shipped.
# Root-anchored: an unanchored `user-testing/` would also swallow the reusable
# skill at .claude/skills/user-testing/, which IS committed.
/user-testing/

# Stray Playwright accessibility-snapshot dumps from browser-driven QA.
ctx*-run.md
page-*.yml

# Antigravity worktrees and state
.gemini/

# Antigravity (Gemini) agent local config — per-machine, like .claude/settings.local.json
.agents/
