-
Notifications
You must be signed in to change notification settings - Fork 0
/
.hookz.yaml
27 lines (27 loc) · 919 Bytes
/
.hookz.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
version: 2.2
hooks:
- type: pre-commit
actions:
- name: "Update all go dependencies to latest"
exec: go
args: ["get", "-u", "./..."]
- name: "Run gofmt to format the code"
exec: gofmt
args: ["-s", "-w", "*.go"]
- name: "errcheck: Check that errors are checked"
exec: errcheck
args: ["./..."]
- name: "gocyclo: Check cyclomatic complexities"
exec: gocyclo
args: ["."]
- name: Hinge
url: https://github.com/devops-kung-fu/hinge/releases/download/v0.0.9/hinge-0.0.9-linux-amd64
args: ["."]
- type: pre-push
actions:
- name: "Go Build (Ensure pulled modules do not break the build)"
exec: go
args: ["build", "-v"]
- name: "Add all changed files during the pre-commit stage"
exec: git
args: ["add", "."]