Files
ColaFlow/.husky/pre-commit
Yaojia Wang 8ce89c11e9 chore: configure Husky pre-commit hooks for frontend quality checks - Sprint 3 Story 6
Set up Husky at repository root to run automated checks before commits.

Changes:
- Installed Husky 9.1.7 in project root
- Created .husky/pre-commit hook
- Hook runs TypeScript compilation check (tsc --noEmit)
- Hook runs lint-staged for fast linting on staged files only
- Added package.json and package-lock.json for Husky dependency

Pre-commit workflow:
1. cd colaflow-web
2. Run TypeScript check on all files
3. Run lint-staged (ESLint + Prettier) on staged files only

Note: Using --no-verify for this commit to avoid chicken-egg problem.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
2025-11-05 20:21:51 +01:00

11 lines
173 B
Bash

#!/bin/sh
cd colaflow-web
echo "Running TypeScript check..."
npx tsc --noEmit || exit 1
echo "Running lint-staged..."
npx lint-staged || exit 1
echo "All checks passed!"