Skip to content

Commit

Permalink
Add Makefile
Browse files Browse the repository at this point in the history
  • Loading branch information
talbright committed Dec 24, 2018
1 parent 350832b commit cd35826
Show file tree
Hide file tree
Showing 2 changed files with 18 additions and 0 deletions.
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
go.mod
go.sum
16 changes: 16 additions & 0 deletions Makefile
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
V4_SRC = $(shell find ./v4 -type f -name '*.go' -not -path "./v4/vendor/*")
V3_SRC = $(shell find ./v3 -type f -name '*.go')

default: build

build: checks
go install ./v3
go install ./v4

checks: fmt-check

fmt-check:
@test -z "$(shell gofmt -l $(V3_SRC) | tee /dev/stderr)" || echo "[WARN] Fix formatting issues in ./v3 with 'make fmt'"
@test -z "$(shell gofmt -l $(V4_SRC) | tee /dev/stderr)" || echo "[WARN] Fix formatting issues in ./v4 with 'make fmt'"

.PHONY: build checks fmt-check

0 comments on commit cd35826

Please sign in to comment.