-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path.pre-commit-config.yaml
91 lines (80 loc) · 2.38 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
# SPDX-License-Identifier: AGPL-3.0-only
# SPDX-FileCopyrightText: 2023 Univention GmbH
---
# See https://pre-commit.com for more information
# See https://pre-commit.com/hooks.html for more hooks
exclude: "patches"
repos:
- repo: "https://github.com/pre-commit/pre-commit-hooks"
rev: "v2.4.0"
hooks:
# "Check for added large files"
- id: "check-added-large-files"
# "Check for merge conflicts"
- id: "check-merge-conflict"
# "Check Yaml"
- id: "check-yaml"
exclude: "^helm/.+/templates/"
# "Fix End of Files"
- id: "end-of-file-fixer"
exclude: "^helm/.+/README.md$"
# "Fix python encoding pragma"
- id: "fix-encoding-pragma"
# "Trim Trailing Whitespace"
- id: "trailing-whitespace"
# flake8
- id: "flake8"
# "Commit messages"
- repo: "https://github.com/compilerla/conventional-pre-commit"
rev: "v2.1.1"
hooks:
- id: "conventional-pre-commit"
stages: ["commit-msg"]
# "Shell Syntax Check"
# This is a wrapper for shellcheck as long as
# shellcheck doesn't have it's own .pre-commit-hooks.yaml
# https://github.com/koalaman/shellcheck/pull/1032
- repo: "https://gitlab.com/univention/pre-commit-hooks/pre-commit-shell"
rev: "v1.0.6"
hooks:
- id: "shell-lint"
# "Dockerfile linter"
- repo: "https://gitlab.com/univention/pre-commit-hooks/docker-pre-commit"
rev: "v2.0.0"
hooks:
- id: "hadolint-system"
# "docker-compose.yaml linter"
- repo: "https://gitlab.com/univention/pre-commit/docker-compose-check"
rev: "7702a8801a158b8595569dd29e2dd655d8a08310"
hooks:
- id: "docker-compose-check"
# ".gitlab-ci.yml linter"
# Disable temporarily because gitlab-api can not be accessed.
# "urllib.error.HTTPError: HTTP Error 401: Unauthorized"
# - repo: https://gitlab.com/univention/pre-commit-hooks/gitlab-ci-linter
# rev: v1.0.1
# hooks:
# - id: gitlab-ci-linter
# args:
# - '--server'
# - 'https://git.knut.univention.de'
# "Helm chart linter"
- repo: https://github.com/gruntwork-io/pre-commit
rev: v0.1.21
hooks:
- id: helmlint
# "Helm docs linter"
- repo: https://github.com/norwoodj/helm-docs
rev: v1.11.0
hooks:
- id: helm-docs
args:
- "--chart-search-root=helm"
- "--template-files=README.md.gotmpl"
always_run: true
- repo: "https://git.knut.univention.de/univention/dist/pre-commit-hooks/addlicense"
rev: "v1.0.0"
hooks:
- id: "addlicense"
name: "Check or add license headers to files"
...