mirror of
https://github.com/opentffoundation/opentf.git
synced 2025-12-19 17:59:05 -05:00
makefile: add .exe when building for Windows (#3452)
Signed-off-by: Larry Bo <laurence.bordowitz@gmail.com>
This commit is contained in:
4
Makefile
4
Makefile
@@ -20,11 +20,13 @@ test-with-coverage:
|
||||
test:
|
||||
go test -v ./...
|
||||
|
||||
EXT := $(shell go env GOEXE)
|
||||
|
||||
# build tofu binary in the current directory with the version set to the git tag
|
||||
# or commit hash if there is no tag.
|
||||
.PHONY: build
|
||||
build:
|
||||
go build -ldflags "-X main.version=$(shell git describe --tags --always --dirty)" -o tofu ./cmd/tofu
|
||||
go build -ldflags "-X main.version=$(shell git describe --tags --always --dirty)" -o tofu$(EXT) ./cmd/tofu
|
||||
|
||||
# generate runs `go generate` to build the dynamically generated
|
||||
# source files, except the protobuf stubs which are built instead with
|
||||
|
||||
Reference in New Issue
Block a user