forked from QubitProducts/exporter_exporter
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathMakefile
41 lines (32 loc) · 815 Bytes
/
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
SHELL := /usr/bin/env bash
GO := go
all: build
clean:
rm -rf dist
.PHONY: test
test:
echo ">> running short tests"
$(GO) test -short $(pkgs)
.PHONY: test-static
test-static:
echo ">> running static tests"
$(GO) vet $(pkgs)
[[ "$(shell gofmt -l $(files))" == "" ]] || (echo "gofmt check failed"; exit 1)
.PHONY: format
format:
echo ">> formatting code"
$(GO) fmt $(pkgs)
.PHONY: vet
vet:
echo ">> vetting code"
$(GO) vet $(pkgs)
.PHONY: AUTHORS
AUTHORS:
# There's only so much credit I need.
git log --format='%aN <%aE>' | grep -v Tristan\ Colgate\ | sort -u > AUTHORS
.PHONY: build
build: vet format test
go run github.com/goreleaser/goreleaser@latest release --snapshot --skip=publish --clean
.PHONY: release
release:
go run github.com/goreleaser/goreleaser@latest release