Skip to content

Commit

Permalink
Allow using alternative go binary on build
Browse files Browse the repository at this point in the history
  • Loading branch information
mumoshu committed Aug 30, 2020
1 parent 0bf58b5 commit 4dbef80
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ PLUGIN_NAME := terraform-provider-helmfile
DIST_PATH := dist/${OS}_${ARCH}
GO_PACKAGES := $(shell go list ./... | grep -v /vendor/)
GO_FILES := $(shell find . -type f -name '*.go')

GO ?= go

.PHONY: all
all: test build
Expand All @@ -16,11 +16,11 @@ test: test-all

.PHONY: test-all
test-all:
@TF_ACC=1 go test -v -race $(GO_PACKAGES)
@TF_ACC=1 $(GO) test -v -race $(GO_PACKAGES)

${DIST_PATH}/${PLUGIN_NAME}: ${GO_FILES}
mkdir -p $(DIST_PATH); \
go build -o $(DIST_PATH)/${PLUGIN_NAME}
$(GO) build -o $(DIST_PATH)/${PLUGIN_NAME}

.PHONY: build
build: ${DIST_PATH}/${PLUGIN_NAME}
Expand Down

0 comments on commit 4dbef80

Please sign in to comment.