Skip to content

Commit 70e725c

Browse files
committed
Makefile: add a target to run tests
For now, just vet and lint. But would like to include the commit validator, once a good range is selectable. Signed-off-by: Vincent Batts <[email protected]>
1 parent 52cbf47 commit 70e725c

File tree

1 file changed

+17
-0
lines changed

1 file changed

+17
-0
lines changed

Makefile

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,7 @@ DOC_FILES := \
1717
glossary.md
1818

1919
docs: pdf html
20+
.PHONY: docs
2021

2122
pdf:
2223
@mkdir -p output/ && \
@@ -40,6 +41,22 @@ html:
4041
vbatts/pandoc -f markdown_github -t html5 -o /output/docs.html $(patsubst %,/input/%,$(DOC_FILES)) && \
4142
ls -sh $(shell readlink -f output/docs.html)
4243

44+
.PHONY: test .govet .golint .gitvalidation
45+
46+
test: .govet .golint
47+
48+
# `go get golang.org/x/tools/cmd/vet`
49+
.govet:
50+
go vet -x ./...
51+
52+
# `go get github.com/golang/lint/golint`
53+
.golint:
54+
golint ./...
55+
56+
# `go get github.com/vbatts/git-validation`
57+
.gitvalidation:
58+
git-validation -run DCO,short-subject -v -range ${TRAVIS_COMMIT_RANGE}
59+
4360
clean:
4461
rm -rf output/ *~
4562

0 commit comments

Comments
 (0)