-
-
Notifications
You must be signed in to change notification settings - Fork 93
Expand file tree
/
Copy path.pre-commit-config.yaml
More file actions
120 lines (107 loc) · 3.02 KB
/
.pre-commit-config.yaml
File metadata and controls
120 lines (107 loc) · 3.02 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
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
minimum_pre_commit_version: "3.2.0"
ci:
autoupdate_schedule: monthly
exclude: |
(?x)(
^resources/patches/|
^resources/playground/|
/generated/|
/vendor/
)
repos:
- repo: meta
hooks:
- id: check-hooks-apply
- id: check-useless-excludes
- repo: local
hooks:
- id: forbid-symlinks
name: Forbid symlinks
entry: Forbid symlinks
language: fail
types: [symlink]
- repo: https://github.com/Lucas-C/pre-commit-hooks
rev: v1.5.6
hooks:
- id: forbid-crlf
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v6.0.0
hooks:
- id: check-added-large-files
- id: check-case-conflict
- id: check-illegal-windows-names
- id: check-executables-have-shebangs
- id: check-merge-conflict
- id: check-shebang-scripts-are-executable
- id: destroyed-symlinks
- id: detect-private-key
- id: end-of-file-fixer
exclude_types: [svg]
- id: fix-byte-order-marker
- id: forbid-submodules
- id: mixed-line-ending
- id: trailing-whitespace
# Trailing whitespace breaks yaml files if you use a multiline string
# with a line that has trailing white space. Many of our recorded
# tests use strings with trailing white space to represent the final
# document contents. For example
# resources/fixtures/recorded/languages/ruby/changeCondition.yml
exclude: |
(?x)(
^resources/fixtures/recorded/.*/[^/]*\.yml$|
^resources/fixtures/scopes/.*/[^/]*\.scope$
)
- repo: local
hooks:
- id: oxlint
name: oxlint
files: \.(ts|tsx)$
language: system
entry: pnpm exec oxlint
args: [--fix]
- repo: local
hooks:
- id: oxfmt
name: oxfmt
types: [text]
language: system
entry: pnpm exec oxfmt
args: [--write, --no-error-on-unmatched-pattern]
- repo: local
hooks:
- id: format-recorded-tests
name: format-recorded-tests
files: ^resources/fixtures/recorded/.*/[^/]*\.yml$
language: system
entry: pnpm transform-recorded-tests
- repo: local
hooks:
- id: check-recorded-test-marks
name: check-recorded-test-marks
files: ^resources/fixtures/recorded/.*/[^/]*\.yml$
language: system
entry: pnpm transform-recorded-tests --check-marks
- repo: https://github.com/astral-sh/ruff-pre-commit
rev: v0.15.7
hooks:
- id: ruff-check
args: [--fix]
- id: ruff-format
- repo: https://github.com/cursorless-dev/talon-tools
rev: v0.9.0
hooks:
- id: talon-fmt
- id: tree-sitter-fmt
- repo: https://github.com/lunarmodules/luacheck
rev: v1.2.0
hooks:
- id: luacheck
- repo: https://github.com/JohnnyMorganz/StyLua
rev: v2.4.0
hooks:
- id: stylua
- repo: https://github.com/koalaman/shellcheck-precommit
rev: v0.11.0
hooks:
- id: shellcheck
name: ShellCheck