-
Notifications
You must be signed in to change notification settings - Fork 22
/
Taskfile.yml
85 lines (72 loc) · 1.59 KB
/
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
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
version: "3"
tasks:
default:
cmds:
- task -l
mod:
desc: download and tidy go modules
cmds:
- go mod download
- go mod tidy
clean:
desc: remove executables, temporary, and cached files
ignore_error: true
cmds:
- rm bin/pillager
- go clean -cache
- rm -rf pkg/pillager/testdata
- mkdir pkg/pillager/testdata
lint:
desc: runs golint
cmds:
- golangci-lint run ./...
test:
desc: run all tests
cmds:
- go test ./...
test:v:
desc: run all tests verbose
cmds:
- go test -v ./...
test:cov:
desc: run all tests and generate coverage
cmds:
- go test -covermode=set -coverprofile=coverage.out ./...
sources:
- ./**/*.go
generates:
- coverage.out
method: checksum
build:
desc: run go build
cmds:
- go build -v -o bin/pillager cmd/pillager/main.go
sources:
- ./**/*.go
generates:
- bin/pillager
method: checksum
install:
desc: install executable
cmds:
- go install github.com/brittonhayes/pillager/cmd/pillager@latest
run:
desc: run the executable
cmds:
- task: build
- bin/pillager
docs:gen:
desc: generate documentation via gomarkdocwn
cmds:
- go generate ./...
docs:serve:
desc: serve godoc server locally
silent: true
cmds:
- echo "Documentation is available at http://localhost:6060/pkg/github.com/brittonhayes/pillager/"
- godoc -http=:6060
dev-setup:
desc: set things up for local development
cmds:
- task: mod
- task: build