Skip to content

Commit

Permalink
Add hook to disallow migrations
Browse files Browse the repository at this point in the history
  • Loading branch information
anneschuth committed Jul 5, 2024
1 parent a857a7d commit ffe0112
Showing 1 changed file with 8 additions and 2 deletions.
10 changes: 8 additions & 2 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,6 @@ repos:
- id: trailing-whitespace
- id: check-yaml
- id: check-json

- id: check-added-large-files
- id: check-merge-conflict
- id: check-toml
Expand All @@ -19,7 +18,14 @@ repos:
hooks:
- id: ruff
- id: ruff-format

- repo: local
hooks:
- id: check-modified-migrations
name: check-modified-migrations
entry: sh -c '! git diff --cached --name-only --diff-filter=MD | grep ^tad/migrations/versions'
language: system
pass_filenames: false
always_run: true
ci:
autofix_prs: false
autofix_commit_msg: "Auto fix pre-commit.com hooks"
Expand Down

0 comments on commit ffe0112

Please sign in to comment.