-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path.pre-commit-config.yaml
42 lines (36 loc) · 1.9 KB
/
.pre-commit-config.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
---
minimum_pre_commit_version: 3.3.0 # Specifies the minimum version of pre-commit required for this configuration
default_install_hook_types: [pre-commit,commit-msg] # Default hook types to install if not specified in individual hooks
repos:
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v4.5.0
hooks:
- id: trailing-whitespace # Removes trailing whitespaces from lines
- id: end-of-file-fixer # Ensures files end with a newline
- id: check-executables-have-shebangs # Checks executables have a proper shebang
- id: mixed-line-ending # Detects mixed line endings (CRLF/LF)
args: ['-f=lf'] # Forces files to use LF line endings
- id: double-quote-string-fixer # Converts single quotes to double quotes in strings
- repo: https://github.com/pylint-dev/pylint
rev: v3.1.0
hooks:
- id: pylint # Runs pylint on Python code
- repo: https://github.com/astral-sh/ruff-pre-commit
rev: v0.3.4
hooks:
- id: ruff # Linter
args: [--fix, --exit-non-zero-on-fix]
- id: ruff-format # Formatter (replaces Black)
- repo: https://github.com/asottile/reorder_python_imports
rev: v3.12.0
hooks:
- id: reorder-python-imports # Reorders Python imports to a standard format (replaces isort)
- repo: https://github.com/pre-commit/mirrors-mypy
rev: v1.9.0
hooks:
- id: mypy # Runs mypy for Python type checking
- repo: https://github.com/espressif/conventional-precommit-linter
rev: v1.6.0
hooks:
- id: conventional-precommit-linter
stages: [commit-msg]