mirror of
https://github.com/vbatts/go-mtree.git
synced 2024-11-25 09:35:39 +00:00
Makefile: add easy target for validation
Hopefully soon adding integration tests for the cli Signed-off-by: Vincent Batts <vbatts@hashbangbash.com>
This commit is contained in:
parent
4f26a7e254
commit
85eacd2163
1 changed files with 35 additions and 0 deletions
35
Makefile
Normal file
35
Makefile
Normal file
|
@ -0,0 +1,35 @@
|
||||||
|
|
||||||
|
SOURCE_FILES := $(shell find . -type f -name "*.go")
|
||||||
|
|
||||||
|
default: validation build
|
||||||
|
|
||||||
|
.PHONY: validation
|
||||||
|
validation: test lint vet
|
||||||
|
|
||||||
|
.PHONY: test
|
||||||
|
test: .test
|
||||||
|
|
||||||
|
.test: $(SOURCE_FILES)
|
||||||
|
go test -v ./... && touch $@
|
||||||
|
|
||||||
|
.PHONY: lint
|
||||||
|
lint: .lint
|
||||||
|
|
||||||
|
.lint: $(SOURCE_FILES)
|
||||||
|
golint -set_exit_status ./... && touch $@
|
||||||
|
|
||||||
|
.PHONY: vet
|
||||||
|
vet: .vet
|
||||||
|
|
||||||
|
.vet: $(SOURCE_FILES)
|
||||||
|
go vet ./... && touch $@
|
||||||
|
|
||||||
|
.PHONY: build
|
||||||
|
build: gomtree
|
||||||
|
|
||||||
|
gomtree: $(SOURCE_FILES)
|
||||||
|
go build ./cmd/gomtree
|
||||||
|
|
||||||
|
clean:
|
||||||
|
rm -rf gomtree
|
||||||
|
|
Loading…
Reference in a new issue