-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathdot_pre-commit-config.yaml
More file actions
65 lines (57 loc) · 1.72 KB
/
dot_pre-commit-config.yaml
File metadata and controls
65 lines (57 loc) · 1.72 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
# Pre-commit hooks configuration
# Install: pip install pre-commit && pre-commit install
# Run manually: pre-commit run --all-files
# See https://pre-commit.com for more information
default_install_hook_types: [pre-commit, commit-msg]
default_stages: [pre-commit]
repos:
# General hooks
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v5.0.0
hooks:
- id: trailing-whitespace
exclude: '\.md$'
- id: end-of-file-fixer
- id: check-yaml
- id: check-json
- id: check-toml
- id: check-added-large-files
args: ['--maxkb=1000']
- id: check-merge-conflict
- id: detect-private-key
# Python - Ruff (linting + formatting)
- repo: https://github.com/astral-sh/ruff-pre-commit
rev: v0.8.6
hooks:
- id: ruff
args: [--fix, --exit-non-zero-on-fix]
- id: ruff-format
# JavaScript/TypeScript - Biome (linting + formatting)
- repo: https://github.com/biomejs/pre-commit
rev: v0.6.0
hooks:
- id: biome-check
additional_dependencies: ["@biomejs/biome@1.9.4"]
args: [--write]
# Commit message linting (conventional commits)
- repo: https://github.com/commitizen-tools/commitizen
rev: v4.1.0
hooks:
- id: commitizen
stages: [commit-msg]
# Shell script linting
- repo: https://github.com/shellcheck-py/shellcheck-py
rev: v0.10.0.1
hooks:
- id: shellcheck
args: [-x] # Follow sourced files
# YAML linting
- repo: https://github.com/adrienverge/yamllint
rev: v1.35.1
hooks:
- id: yamllint
args: [-d, relaxed]
# CI configuration
ci:
autofix_commit_msg: "style: auto-fix by pre-commit hooks"
autoupdate_commit_msg: "chore: update pre-commit hooks"