-
-
Notifications
You must be signed in to change notification settings - Fork 0
/
.pre-commit-config.yaml
142 lines (142 loc) · 4.39 KB
/
.pre-commit-config.yaml
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
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
repos:
# Syncs pre-commit dependencies with the latest versions.
- repo: https://github.com/mxr/sync-pre-commit-deps
rev: "v0.0.1"
hooks:
- id: sync-pre-commit-deps
# Pre-commit hooks for general file checks
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: "v5.0.0"
hooks:
- id: check-added-large-files
- id: check-ast
- id: check-builtin-literals
- id: check-case-conflict
- id: check-docstring-first
- id: check-executables-have-shebangs
- id: check-json
- id: check-merge-conflict
- id: check-shebang-scripts-are-executable
- id: check-symlinks
- id: check-toml
- id: check-vcs-permalinks
- id: check-xml
- id: check-yaml
- id: debug-statements
- id: destroyed-symlinks
# - id: detect-aws-credentials
- id: detect-private-key
- id: double-quote-string-fixer
- id: end-of-file-fixer
- id: fix-byte-order-marker
- id: mixed-line-ending
- id: name-tests-test
- id: pretty-format-json
args: [--autofix]
- id: requirements-txt-fixer
- id: trailing-whitespace
# Uses pygrep to enforce Python type annotations.
- repo: https://github.com/pre-commit/pygrep-hooks
rev: "v1.10.0"
hooks:
- id: python-use-type-annotations
# Clang-format for formatting C, C++, and JavaScript files
- repo: https://github.com/pre-commit/mirrors-clang-format
rev: "v19.1.4"
hooks:
- id: clang-format
# ESLint for linting JavaScript and TypeScript files
- repo: https://github.com/pre-commit/mirrors-eslint
rev: "v9.16.0"
hooks:
- id: eslint
# Runs mypy to check Python type annotations.
- repo: https://github.com/pre-commit/mirrors-mypy
rev: "v1.13.0"
hooks:
- id: mypy
# Lints SCSS files to enforce style and best practices.
- repo: https://github.com/pre-commit/mirrors-scss-lint
rev: "v0.60.0"
hooks:
- id: scss-lint
# Runs JSHint to analyze JavaScript code for potential errors.
- repo: https://github.com/pre-commit/mirrors-jshint
rev: "v2.13.6"
hooks:
- id: jshint
# Uses fixmyjs to automatically fix simple JavaScript issues.
- repo: https://github.com/pre-commit/mirrors-fixmyjs
rev: "v2.0.0"
hooks:
- id: fixmyjs
# Runs CSSLint to check CSS files for errors and stylistic issues.
- repo: https://github.com/pre-commit/mirrors-csslint
rev: "v1.0.5"
hooks:
- id: csslint
# ShellCheck hook for linting shell scripts
- repo: https://github.com/shellcheck-py/shellcheck-py
rev: "v0.10.0.1"
hooks:
- id: shellcheck
name: shellcheck
description: This hook runs shellcheck for linting shell scripts
# Bashate hook for linting shell scripts
- repo: https://github.com/openstack/bashate
rev: "2.1.1"
hooks:
- id: bashate
name: bashate
description: This hook runs bashate for linting shell scripts
entry: bashate
language: python
types: [shell]
# Actionlint for linting GitHub Actions YAML files
- repo: https://github.com/rhysd/actionlint
rev: "v1.7.4"
hooks:
- id: actionlint
# Yamlfmt for formatting YAML files
- repo: https://github.com/google/yamlfmt
rev: "v0.14.0"
hooks:
- id: yamlfmt
# Codespell for detecting common misspellings in code
- repo: https://github.com/codespell-project/codespell
rev: "v2.3.0"
hooks:
- id: codespell
# Checkmake for linting Makefiles
- repo: https://github.com/mrtazz/checkmake
rev: "0.2.2"
hooks:
- id: checkmake
# SQLFluff for linting and fixing SQL files
- repo: https://github.com/sqlfluff/sqlfluff
rev: "3.2.5"
hooks:
- id: sqlfluff-lint
- id: sqlfluff-fix
# RuboCop for linting Ruby files
- repo: https://github.com/rubocop/rubocop
rev: "v1.69.0"
hooks:
- id: rubocop
# Terraform-py for formatting and validating Terraform files
- repo: https://github.com/AleksaC/terraform-py
rev: "v1.10.0"
hooks:
- id: tf-fmt
- id: tf-validate
# Gitleaks for detecting secrets in Git repositories
- repo: https://github.com/gitleaks/gitleaks
rev: "v8.21.2"
hooks:
- id: gitleaks
# Talisman for pre-commit Git hooks to detect sensitive files
- repo: https://github.com/thoughtworks/talisman
rev: "v1.32.0"
hooks:
- id: talisman-commit
entry: cmd --githook pre-commit