-
Notifications
You must be signed in to change notification settings - Fork 2
Expand file tree
/
Copy path.pre-commit-config.yaml
More file actions
77 lines (70 loc) · 2.09 KB
/
.pre-commit-config.yaml
File metadata and controls
77 lines (70 loc) · 2.09 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
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
# See https://pre-commit.com for more information
# See https://pre-commit.com/hooks.html for more hooks
exclude: '\.git/|__pycache__/|\.pyc'
repos:
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v6.0.0
hooks:
- id: check-added-large-files
name: Block large files
args: [--maxkb=500]
- id: check-ast
name: Validate Python syntax
- id: check-merge-conflict
name: Detect merge conflicts
- id: check-symlinks
name: Validate symlinks
- id: check-toml
name: Validate TOML syntax
- id: check-yaml
name: Validate YAML syntax
- id: file-contents-sorter
name: Sort .gitignore
files: \.gitignore
- id: trailing-whitespace
name: Trim whitespace
- repo: https://github.com/Lucas-C/pre-commit-hooks
rev: v1.5.5
hooks:
- id: remove-tabs
name: Replace tabs with spaces
- repo: https://github.com/sirosen/texthooks
rev: 0.7.1
hooks:
- id: fix-smartquotes
name: Fix smart quotes
- id: forbid-bidi-controls
name: Forbid bidirectional text (security)
# Ruff replaces flake8, pylint, isort and more
- repo: https://github.com/astral-sh/ruff-pre-commit
rev: v0.14.0
hooks:
# Run the linter with auto-fix
- id: ruff
name: Fix Python issues (Ruff)
args: [--fix]
# Run the formatter
- id: ruff-format
name: Format Python (Ruff)
# Prettier for JS, JSON, YAML, Markdown, etc. No web/agent assumptions
- repo: https://github.com/rbubley/mirrors-prettier
rev: v3.6.2
hooks:
- id: prettier
name: Format with Prettier
types_or:
["javascript", "jsx", "ts", "tsx", "css", "scss", "json", "yaml", "markdown"]
exclude: |
(?x)^(
.*\.min\.(js|css)|
.*\.next/|
.*migrations/|
.*out/|
.*node_modules/|
pnpm-lock\.yaml
)$
- repo: https://github.com/rhysd/actionlint
rev: v1.7.8
hooks:
- id: actionlint
name: Check Github Actions