📦 build: add lefthook pre-commit hooks matching CI checks

This commit is contained in:
2026-07-13 23:15:50 +07:00
parent e29c6e1dfa
commit cfca7971e0
2 changed files with 32 additions and 1 deletions
+15
View File
@@ -0,0 +1,15 @@
pre-commit:
parallel: true
commands:
format:
glob: "*.go"
run: test -z "$(gofmt -l {staged_files})"
vet:
glob: "*.go"
run: go vet ./src/...
lint:
glob: "*.go"
run: golangci-lint run ./src/...
test:
glob: "*.go"
run: go test ./src/...