diff options
Diffstat (limited to 'client/go/Makefile')
-rw-r--r-- | client/go/Makefile | 30 |
1 files changed, 19 insertions, 11 deletions
diff --git a/client/go/Makefile b/client/go/Makefile index 0bd7325ef33..63922acb518 100644 --- a/client/go/Makefile +++ b/client/go/Makefile @@ -31,10 +31,13 @@ all: test checkfmt install # # Example: # -# $ git checkout vX.Y.Z -# $ make dist-homebrew -dist-homebrew: dist-version - brew bump-formula-pr --version $(VERSION) --no-browse vespa-cli +# $ make maybe-dist-homebrew +--dist-homebrew: dist-version +# TODO(mpolden): Remove --dry-run when this is ready + brew bump-formula-pr --dry-run --version $(VERSION) --no-browse vespa-cli + +dist-homebrew: + go run cond_make.go --dist-homebrew # Create a GitHub release draft for all platforms. Note that this only creates a # draft, which is not publicly visible until it's explicitly published. @@ -45,13 +48,16 @@ dist-homebrew: dist-version # # Example: # -# $ git checkout vX.Y.Z -# $ make dist-github -dist-github: dist - gh release create v$(VERSION) --repo vespa-engine/vespa --notes-file $(CURDIR)/README.md --draft --title "Vespa CLI $(VERSION)" \ +# $ make maybe-dist-github +--dist-github: dist +# TODO(mpolden): Remove @echo when this is ready + @echo gh release create v$(VERSION) --repo vespa-engine/vespa --notes-file $(CURDIR)/README.md --title "Vespa CLI $(VERSION)" \ $(DIST)/vespa-cli_$(VERSION)_sha256sums.txt \ $(DIST)/vespa-cli_$(VERSION)_*.{zip,tar.gz} +dist-github: + go run cond_make.go --dist-github + # # Cross-platform build targets # @@ -80,7 +86,7 @@ $(DIST_TARGETS): DIST_NAME=vespa-cli_$(VERSION)_$(GOOS)_$(GOARCH) $(DIST_TARGETS): dist-version ci manpages $(DIST_TARGETS): mkdir -p $(DIST)/$(DIST_NAME)/bin - env GOOS=$(GOOS) GOARCH=$(GOARCH) $(GOPROXY_OVERRIDE) go build -o $(DIST)/$(DIST_NAME)/bin $(GO_FLAGS) ./... + env GOOS=$(GOOS) GOARCH=$(GOARCH) go build -o $(DIST)/$(DIST_NAME)/bin $(GO_FLAGS) ./... cp -a $(GIT_ROOT)/LICENSE $(DIST)/$(DIST_NAME) if [ "$(GOOS)" = "windows" ]; then \ cd $(DIST) && zip -r $(DIST)/$(DIST_NAME).zip $(DIST_NAME); \ @@ -110,6 +116,9 @@ ifdef CI go env endif +install-brew: + brew install vespa-cli + install: ci env GOBIN=$(BIN) go install $(GO_FLAGS) ./... @@ -120,8 +129,7 @@ manpages: install clean: rm -rf $(DIST) rm -f $(BIN)/vespa $(SHARE)/man/man1/vespa.1 $(SHARE)/man/man1/vespa-*.1 - rmdir -p $(BIN) &> /dev/null || true - rmdir -p $(SHARE)/man/man1 &> /dev/null || true + rmdir -p $(BIN) $(SHARE)/man/man1 &> /dev/null || true test: ci go test ./... |