lefthook.yml 634 B

1234567891011121314151617181920212223
  1. # Git hooks (lefthook). Keep these local checkpoints fast; CI owns the full
  2. # repository-wide gate matrix.
  3. # Install: `pnpm exec lefthook install` (runs automatically via postinstall).
  4. pre-commit:
  5. jobs:
  6. - name: lint (staged)
  7. glob: '*.{ts,tsx,mts,cts,mjs}'
  8. exclude:
  9. - 'vendor/*/src/**'
  10. run: node_modules/.bin/eslint --fix {staged_files}
  11. stage_fixed: true
  12. - name: whitespace (staged)
  13. run: git diff --cached --check
  14. - name: vendor manifest guard
  15. run: scripts/check-vendor-manifest.sh
  16. pre-push:
  17. jobs:
  18. - name: typecheck
  19. run: node_modules/.bin/tsc -b --pretty false