-
Notifications
You must be signed in to change notification settings - Fork 8
/
Taskfile.yml
executable file
·42 lines (34 loc) · 840 Bytes
/
Taskfile.yml
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
version: "3"
tasks:
default:
deps: [dev]
dev:
summary: "Development mode"
cmd: go run .
build:
summary: "Build application"
cmd: go build -o dist/up .
clean:
summary: "Clean the project"
cmd: go clean
dep:
summary: "Install dev dependencies"
cmds:
# Linters.
- go install honnef.co/go/tools/cmd/staticcheck@latest
- go install github.com/securego/gosec/v2/cmd/gosec@latest
# Formatters.
- go install github.com/segmentio/golines@latest
fmt:
summary: "Format the code"
# Already runs `go fmt` before finishing.
cmd: golines -m 80 --shorten-comments -w .
vet:
summary: "Run linters"
cmds:
- go vet ./...
- staticcheck ./...
- gosec -fmt=golint -quiet ./...
test:
summary: "Run tests"
cmd: go test -v ./...