-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fixes #25
- Loading branch information
Trevor Rosen
committed
Jan 14, 2020
1 parent
4a7bf1e
commit 7e20b8b
Showing
12 changed files
with
9 additions
and
535 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,52 +1,21 @@ | ||
TEST?=$$(go list ./... |grep -v 'vendor') | ||
WEBSITE_REPO=github.com/hashicorp/terraform-website | ||
PKG_NAME=librato | ||
plugin_name=terraform-provider-appoptics | ||
plugin_path=~/.terraform.d/plugins | ||
.PHONY: build test testacc vet lint release | ||
|
||
plugin_name=terraform-provider-appoptics | ||
|
||
default: build | ||
|
||
build: | ||
go build -o $(plugin_name) | ||
|
||
user-install: | ||
mkdir -p $(plugin_path) && go build -o $(plugin_path)/$(plugin_name) | ||
test: | ||
go test ./... | ||
|
||
test: fmtcheck | ||
go test -i $(TEST) || exit 1 | ||
echo $(TEST) | \ | ||
xargs -t -n4 go test $(TESTARGS) -timeout=30s -parallel=4 | ||
|
||
testacc: fmtcheck | ||
TF_ACC=1 go test $(TEST) -v $(TESTARGS) -timeout 120m | ||
testacc: | ||
TF_ACC=1 go test -v -timeout 120m | ||
|
||
vet: | ||
@echo "go vet ." | ||
@go vet $$(go list ./... | grep -v vendor/) ; if [ $$? -eq 1 ]; then \ | ||
echo ""; \ | ||
echo "Vet found suspicious constructs. Please check the reported constructs"; \ | ||
echo "and fix them if necessary before submitting the code for review."; \ | ||
exit 1; \ | ||
fi | ||
|
||
fmtcheck: | ||
@sh -c "'$(CURDIR)/scripts/gofmtcheck.sh'" | ||
|
||
errcheck: | ||
@sh -c "'$(CURDIR)/scripts/errcheck.sh'" | ||
|
||
vendor-status: | ||
@govendor status | ||
|
||
test-compile: | ||
@if [ "$(TEST)" = "./..." ]; then \ | ||
echo "ERROR: Set TEST to a specific package. For example,"; \ | ||
echo " make test-compile TEST=./$(PKG_NAME)"; \ | ||
exit 1; \ | ||
fi | ||
go test -c $(TEST) $(TESTARGS) | ||
|
||
go vet ./... | ||
|
||
.PHONY: build test testacc vet fmt fmtcheck errcheck vendor-status test-compile website website-test | ||
lint: | ||
"$$(go env GOPATH)/bin/golangci-lint" run | ||
|
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
Oops, something went wrong.