# Run quick checks before commit (typecheck + lint + format only).
# Protected branches still enforce full CI parity in .husky/pre-push.
# Feature branches use a faster pre-push gate plus GitHub CI.
bun run typecheck && bun run lint:fix && bun run format:check

# Validate UI if changes detected (typecheck + lint only)
if git diff --cached --name-only | grep -q "^ui/"; then
  echo "[i] UI changes detected, running ui:validate..."
  bun run ui:validate
fi
