Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
16 changes: 13 additions & 3 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -27,8 +27,8 @@ else
GOBIN=$(shell go env GOBIN)
endif


LATEST_TAG=$(shell git describe --tags --abbrev=0 2>/dev/null)
LATEST_TAG=$(shell git describe --tags `git rev-list --tags --max-count=1` 2>/dev/null)
#LATEST_TAG=$(shell git describe --tags --abbrev=0 2>/dev/null)
LATEST_COMMIT=$(shell git rev-parse --short HEAD 2>/dev/null)

BUILD_DATE=$(shell date +"%Y%m%d-%T")
Expand Down Expand Up @@ -101,8 +101,18 @@ test: manifests generate fmt vet envtest ## Run tests.

##@ Build

.PHONY: helm
helm: #replace variable
ifeq ($(shell uname),Darwin)
sed -i "" "s/{operatorVersion}/$(VERSION)/g" helm-charts/doris/Chart.yaml
sed -i "" "s/{operatorVersion}/$(VERSION)/g" helm-charts/doris-operator/Chart.yaml
else
sed -i "s/{operatorVersion}/$(VERSION)/g" helm-charts/doris/Chart.yaml
sed -i "s/{operatorVersion}/$(VERSION)/g" helm-charts/doris-operator/Chart.yaml
endif

.PHONY: build
build: manifests generate fmt vet ## Build manager binary.
build: manifests generate fmt vet helm ## Build manager binary.
go build -ldflags=$(LDFLAGS) -o bin/dorisoperator cmd/operator/main.go

.PHONY: run
Expand Down