Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Enable pre-commit.ci and enable config file sorting #697

Merged
merged 1 commit into from
Dec 15, 2023
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
16 changes: 11 additions & 5 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
@@ -1,3 +1,10 @@
ci:
autofix_commit_msg: "[pre-commit.ci] auto fixes from pre-commit.com hooks"
autofix_prs: true
autoupdate_commit_msg: "[pre-commit.ci] pre-commit autoupdate"
autoupdate_schedule: weekly
submodules: false

repos:
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v2.5.0
Expand All @@ -8,13 +15,15 @@ repos:
- id: end-of-file-fixer
- id: trailing-whitespace
args: [--markdown-linebreak-ext=md]

- id: end-of-file-fixer
- id: mixed-line-ending
- id: sort-simple-yaml
files: .pre-commit-config.yaml
- repo: https://github.com/pre-commit/pygrep-hooks
rev: v1.5.1
hooks:
- id: python-check-blanket-noqa # Enforce noqa annotations (noqa: F401,W203)
- id: python-use-type-annotations # Enforce type annotations instead of type comments

- repo: local
hooks:
- id: black
Expand All @@ -23,7 +32,6 @@ repos:
entry: poetry run black
language: system
types: [python]

- repo: local
hooks:
- id: ruff
Expand All @@ -34,7 +42,6 @@ repos:
types: [python]
require_serial: true
args: [--fix, --exit-non-zero-on-fix]

- repo: local
hooks:
- id: isort
Expand All @@ -43,7 +50,6 @@ repos:
entry: poetry run isort
language: system
types: [python]

- repo: local
hooks:
- id: pyright
Expand Down
Loading