-
Notifications
You must be signed in to change notification settings - Fork 27
/
Makefile
86 lines (64 loc) · 1.72 KB
/
Makefile
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
.PHONY: example-pokemon
example-pokemon:
@go run ./examples/pokemon/*.go
.PHONY: example-metadata
example-metadata:
@go run ./examples/metadata/*.go
.PHONY: example-dimensions
example-dimensions:
@go run ./examples/dimensions/main.go
.PHONY: example-events
example-events:
@go run ./examples/events/main.go
.PHONY: example-features
example-features:
@go run ./examples/features/main.go
.PHONY: example-multiline
example-multiline:
@go run ./examples/multiline/main.go
.PHONY: example-filter
example-filter:
@go run ./examples/filter/*.go
.PHONY: example-filterapi
example-filterapi:
@go run ./examples/filterapi/*.go
.PHONY: example-flex
example-flex:
@go run ./examples/flex/*.go
.PHONY: example-pagination
example-pagination:
@go run ./examples/pagination/*.go
.PHONY: example-simplest
example-simplest:
@go run ./examples/simplest/*.go
.PHONY: example-scrolling
example-scrolling:
@go run ./examples/scrolling/*.go
.PHONY: example-sorting
example-sorting:
@go run ./examples/sorting/*.go
.PHONY: example-updates
example-updates:
@go run ./examples/updates/*.go
.PHONY: test
test:
@go test -race -cover ./table
.PHONY: test-coverage
test-coverage: coverage.out
@go tool cover -html=coverage.out
.PHONY: benchmark
benchmark:
@go test -run=XXX -bench=. -benchmem ./table
.PHONY: lint
lint: ./bin/golangci-lint
@./bin/golangci-lint run ./table
coverage.out: table/*.go go.*
@go test -coverprofile=coverage.out ./table
.PHONY: fmt
fmt: ./bin/gci
@go fmt ./...
@./bin/gci write --skip-generated ./table/*.go
./bin/golangci-lint:
curl -sSfL https://raw.githubusercontent.com/golangci/golangci-lint/master/install.sh | sh -s -- -b ./bin v1.51.1
./bin/gci:
GOBIN=$(shell pwd)/bin go install github.com/daixiang0/[email protected]