forked from espanso/espanso
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy path.pre-commit-config.yaml
More file actions
54 lines (48 loc) · 1.28 KB
/
.pre-commit-config.yaml
File metadata and controls
54 lines (48 loc) · 1.28 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
fail_fast: true
exclude: |
(?x)^(
.vscode/
|.devcontainer/
|docs/.vscode/
)
repos:
- repo: https://github.com/biomejs/pre-commit
rev: v2.1.3
hooks:
- id: biome-check
files: "\\.(jsx?|tsx?|c(js|ts)|m(js|ts)|d\\.(ts|cts|mts)|jsonc?|css|svelte|vue|astro|graphql|gql)$"
- repo: local
hooks:
- id: cargo-fmt
name: cargo fmt
entry: cargo fmt --
language: system
types: [rust]
pass_filenames: false # This makes it a lot faster
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v5.0.0
hooks:
- id: check-yaml
- id: check-toml
- id: check-json
- id: no-commit-to-branch
name: no-commit-to-branch
args: ["--pattern", "master|dev"]
# not working
# - repo: local
# hooks:
# - id: clang-format
# name: clang-format
# entry: ./scripts/format_clang.sh
# language: script
# pass_filenames: true
- repo: local
hooks:
- id: check-todos
name: Check for TODO comments
# entry: sh -c 'rg "TODO" && exit 1 || exit 0'
# entry: rg 'auca' --quiet
entry: nu -c 'if (rg "TODO" | complete).exit_code == 0 { exit 1 } else { exit 0 }'
language: system
pass_filenames: false
files: '.*'