Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions .markdownlint.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
default: true

MD013: false
76 changes: 76 additions & 0 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,76 @@
default_install_hook_types:
- pre-commit
- pre-push

repos:
# Go checks use the repository's configured Go toolchain.
- repo: local
hooks:
- id: go-fmt
name: gofmt
entry: gofmt -w
language: system
types: [go]

- id: go-mod-tidy
name: go mod tidy
entry: go mod tidy
language: system
pass_filenames: false
files: '(^|/)(go\.(mod|sum)|.*\.go)$'

- id: go-build
name: go build
entry: go build ./...
language: system
pass_filenames: false
files: '(^|/)(go\.(mod|sum)|.*\.go)$'

- id: go-unit-tests
name: go test
entry: go test ./...
language: system
pass_filenames: false
files: '(^|/)(go\.(mod|sum)|.*\.go)$'

- id: golangci-lint
name: golangci-lint
entry: golangci-lint run
language: system
pass_filenames: false
files: '(^|/)(go\.(mod|sum)|.*\.go)$'

- id: go-e2e-tests
name: go test (e2e)
entry: go test -tags=e2e -v .
language: system
pass_filenames: false
files: '(^|/)(go\.(mod|sum)|.*\.go)$'
stages:
- pre-push
- manual

- repo: https://github.com/igorshubovych/markdownlint-cli
rev: v0.49.1
hooks:
- id: markdownlint
args: [--fix]

- repo: https://github.com/codespell-project/codespell
rev: v2.4.3
hooks:
- id: codespell
name: codespell


- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v6.0.0
hooks:
- id: trailing-whitespace
- id: end-of-file-fixer
- id: check-yaml
- id: check-toml
- id: check-added-large-files
args: [--maxkb=5000]
- id: check-merge-conflict
- id: check-case-conflict