forked from oxyno-zeta/golang-graphql-example
-
Notifications
You must be signed in to change notification settings - Fork 0
/
.pre-commit-config.yaml
90 lines (90 loc) · 2.76 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
# See https://pre-commit.com for more information
# See https://pre-commit.com/hooks.html for more hooks
default_install_hook_types:
- pre-commit
- commit-msg
repos:
- repo: https://github.com/commitizen-tools/commitizen
rev: v3.29.1
hooks:
- id: commitizen
stages: [commit-msg]
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v5.0.0
hooks:
- id: check-json
stages: [pre-commit]
- id: check-merge-conflict
stages: [pre-commit]
- id: trailing-whitespace
stages: [pre-commit]
exclude: \.test\.tsx\.snap|\.yarn\/releases\/.*\.cjs$
- id: end-of-file-fixer
stages: [pre-commit]
- id: check-yaml
stages: [pre-commit]
- id: check-added-large-files
stages: [pre-commit]
exclude: \.yarn\/releases\/.*\.cjs$
- id: check-executables-have-shebangs
stages: [pre-commit]
- id: detect-aws-credentials
stages: [pre-commit]
- id: detect-private-key
stages: [pre-commit]
- id: check-symlinks
stages: [pre-commit]
- id: check-shebang-scripts-are-executable
stages: [pre-commit]
- id: check-toml
stages: [pre-commit]
- repo: https://github.com/pre-commit/mirrors-prettier
# Use the sha or branch you want to point at
rev: v3.1.0
hooks:
- id: prettier
stages: [pre-commit]
- repo: https://github.com/shellcheck-py/shellcheck-py
rev: v0.10.0.1
hooks:
- id: shellcheck
stages: [pre-commit]
- repo: https://github.com/zricethezav/gitleaks
rev: v8.21.0
hooks:
- id: gitleaks
stages: [pre-commit]
- repo: local
hooks:
- id: backend-lint
stages: [pre-commit]
files: \.go$
name: Backend Lint
entry: ./run-sub-folder-task.sh backend "make code/lint"
require_serial: false
language: script
pass_filenames: false
- id: backend-graphql-concat
stages: [pre-commit]
files: \.graphql$
name: Backend graphql concat
entry: ./run-sub-folder-task.sh backend "make code/graphql/concat"
require_serial: true
language: script
pass_filenames: false
- id: backend-graphql-no-break-check
stages: [pre-commit]
files: \.graphql$
name: Backend graphql no breaking check
entry: ./run-sub-folder-task.sh backend "make code/graphql/no-break-check"
require_serial: true
language: script
pass_filenames: false
- id: frontend-lint
stages: [pre-commit]
files: \.(tsx|ts|js|jsx)$
name: Frontend lint
entry: ./run-sub-folder-task.sh frontend "yarn lint"
require_serial: false
language: script
pass_filenames: false