summaryrefslogtreecommitdiffstats
path: root/vendor/go.uber.org/multierr/Makefile
diff options
context:
space:
mode:
authorWim <wim@42.be>2020-08-10 00:29:54 +0200
committerGitHub <noreply@github.com>2020-08-10 00:29:54 +0200
commit4e50fd864921c556988c919269448efdb90fa961 (patch)
treea3625f03f8de3c4f3841364000a4ea3aa42c1533 /vendor/go.uber.org/multierr/Makefile
parentdfdffa0027334e55ce213fc6eb62206dbf48baf6 (diff)
downloadmatterbridge-msglm-4e50fd864921c556988c919269448efdb90fa961.tar.gz
matterbridge-msglm-4e50fd864921c556988c919269448efdb90fa961.tar.bz2
matterbridge-msglm-4e50fd864921c556988c919269448efdb90fa961.zip
Use mattermost v5 module (#1192)
Diffstat (limited to 'vendor/go.uber.org/multierr/Makefile')
-rw-r--r--vendor/go.uber.org/multierr/Makefile56
1 files changed, 12 insertions, 44 deletions
diff --git a/vendor/go.uber.org/multierr/Makefile b/vendor/go.uber.org/multierr/Makefile
index a7437d06..41601823 100644
--- a/vendor/go.uber.org/multierr/Makefile
+++ b/vendor/go.uber.org/multierr/Makefile
@@ -1,23 +1,17 @@
-export GO15VENDOREXPERIMENT=1
-
-PACKAGES := $(shell glide nv)
+# Directory to put `go install`ed binaries in.
+export GOBIN ?= $(shell pwd)/bin
GO_FILES := $(shell \
find . '(' -path '*/.*' -o -path './vendor' ')' -prune \
-o -name '*.go' -print | cut -b3-)
-.PHONY: install
-install:
- glide --version || go get github.com/Masterminds/glide
- glide install
-
.PHONY: build
build:
- go build -i $(PACKAGES)
+ go build ./...
.PHONY: test
test:
- go test -cover -race $(PACKAGES)
+ go test -race ./...
.PHONY: gofmt
gofmt:
@@ -25,50 +19,24 @@ gofmt:
@gofmt -e -s -l $(GO_FILES) > $(FMT_LOG) || true
@[ ! -s "$(FMT_LOG)" ] || (echo "gofmt failed:" | cat - $(FMT_LOG) && false)
-.PHONY: govet
-govet:
- $(eval VET_LOG := $(shell mktemp -t govet.XXXXX))
- @go vet $(PACKAGES) 2>&1 \
- | grep -v '^exit status' > $(VET_LOG) || true
- @[ ! -s "$(VET_LOG)" ] || (echo "govet failed:" | cat - $(VET_LOG) && false)
-
.PHONY: golint
golint:
- @go get github.com/golang/lint/golint
- $(eval LINT_LOG := $(shell mktemp -t golint.XXXXX))
- @cat /dev/null > $(LINT_LOG)
- @$(foreach pkg, $(PACKAGES), golint $(pkg) >> $(LINT_LOG) || true;)
- @[ ! -s "$(LINT_LOG)" ] || (echo "golint failed:" | cat - $(LINT_LOG) && false)
+ @go install golang.org/x/lint/golint
+ @$(GOBIN)/golint ./...
.PHONY: staticcheck
staticcheck:
- @go get honnef.co/go/tools/cmd/staticcheck
- $(eval STATICCHECK_LOG := $(shell mktemp -t staticcheck.XXXXX))
- @staticcheck $(PACKAGES) 2>&1 > $(STATICCHECK_LOG) || true
- @[ ! -s "$(STATICCHECK_LOG)" ] || (echo "staticcheck failed:" | cat - $(STATICCHECK_LOG) && false)
+ @go install honnef.co/go/tools/cmd/staticcheck
+ @$(GOBIN)/staticcheck ./...
.PHONY: lint
-lint: gofmt govet golint staticcheck
+lint: gofmt golint staticcheck
.PHONY: cover
cover:
- ./scripts/cover.sh $(shell go list $(PACKAGES))
+ go test -coverprofile=cover.out -coverpkg=./... -v ./...
go tool cover -html=cover.out -o cover.html
update-license:
- @go get go.uber.org/tools/update-license
- @update-license \
- $(shell go list -json $(PACKAGES) | \
- jq -r '.Dir + "/" + (.GoFiles | .[])')
-
-##############################################################################
-
-.PHONY: install_ci
-install_ci: install
- go get github.com/wadey/gocovmerge
- go get github.com/mattn/goveralls
- go get golang.org/x/tools/cmd/cover
-
-.PHONY: test_ci
-test_ci: install_ci
- ./scripts/cover.sh $(shell go list $(PACKAGES))
+ @go install go.uber.org/tools/update-license
+ @$(GOBIN)/update-license $(GO_FILES)