-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathlefthook.yml
More file actions
32 lines (32 loc) · 869 Bytes
/
lefthook.yml
File metadata and controls
32 lines (32 loc) · 869 Bytes
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
pre-commit:
parallel: false
commands:
gofmt:
glob: "*.go"
run: gofmt -w {staged_files}
stage_fixed: true
golangci-lint:
run: golangci-lint run ./cmd/... ./internal/...
go-test:
run: go test ./...
property-tests:
run: ./scripts/property_test.sh
govulncheck:
run: |
if command -v govulncheck >/dev/null 2>&1; then
govulncheck ./...
elif [ -x "$(go env GOPATH)/bin/govulncheck" ]; then
"$(go env GOPATH)/bin/govulncheck" ./...
else
echo "govulncheck is required for pre-commit. Install it with: go install golang.org/x/vuln/cmd/govulncheck@v1.1.4" >&2
exit 1
fi
pre-push:
parallel: false
commands:
live-e2e-smoke:
interactive: true
glob:
- "*.go"
- "**/*.go"
run: ./scripts/e2e_live_smoke.sh