forked from sean2077/jsonpath-python
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy path.pre-commit-config.yaml
More file actions
52 lines (48 loc) · 1.29 KB
/
.pre-commit-config.yaml
File metadata and controls
52 lines (48 loc) · 1.29 KB
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
43
44
45
46
47
48
49
50
51
52
exclude: (^vendor/)
repos:
# Basic file checks
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v6.0.0
hooks:
# Remove trailing whitespace
- id: trailing-whitespace
# Ensure files end with newline
- id: end-of-file-fixer
# Check for merge conflict markers
# - id: check-merge-conflict
# Check for large files being added
- id: check-added-large-files
args: ["--maxkb=200000"]
# Ruff - Python linting and formatting
- repo: https://github.com/astral-sh/ruff-pre-commit
rev: v0.14.6
hooks:
# Run ruff linter
- id: ruff-check
args: ["--fix"]
types_or: [python, pyi]
exclude: ^(vendor/)
# Run ruff formatter
- id: ruff-format
types_or: [python, pyi]
# shfmt - Shell script formatting
- repo: https://github.com/scop/pre-commit-shfmt
rev: v3.12.0-2
hooks:
- id: shfmt
args: ["-i", "2", "-w"]
types_or: [shell]
# Prettier (local) - JSON/YAML/TOML formatting
- repo: local
hooks:
- id: prettier-local
name: prettier (local)
alias: prettier
entry: npx --yes prettier
language: system
types_or:
- json
- yaml
args:
- "-w"
- "--tab-width=2"