patchwise-agent-studio / .pre-commit-config.yaml
EnergyVenom's picture
Patchwise Agent Studio: Oracle AI Agent Studio cycles
af1bee9 verified
Raw History Blame Contribute Delete
1.19 kB
# pre-commit install (once per clone) -> these checks run on every commit; CI runs the same and more.
repos:
- repo: https://github.com/astral-sh/ruff-pre-commit
rev: v0.14.0
hooks:
- id: ruff
args: [--fix]
files: ^(coworker|triage|reports|qa)/
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v5.0.0
hooks:
- id: check-yaml
exclude: ^tests/cases/
- id: check-json
exclude: ^(web/src/api/openapi\.json|.*tsconfig.*\.json)$
- id: check-merge-conflict
- id: detect-private-key
- id: check-added-large-files
args: [--maxkb=2048]
- repo: local
hooks:
- id: web-typecheck-lint
name: web type-check and lint
entry: bash -c 'cd web && npx tsc -b && npx eslint . --max-warnings=0'
language: system
files: ^web/src/
pass_filenames: false
- id: no-secrets
name: no real keys or tokens
entry: bash -c '! git diff --cached -U0 | grep -E "^\+.*(hf_[A-Za-z0-9]{30,}|nvapi-[A-Za-z0-9_-]{30,}|sbp_[a-f0-9]{30,}|sk-[A-Za-z0-9]{30,})"'
language: system
pass_filenames: false