Update Versioning to Improve Output (#5000)

* Update Versioning to Improve Output

* Always get commit from build info, always get date and version from ldflag

* Just replace broken main output with semver and deprecate short flag as is

---------

Co-authored-by: Katrina Verey <katrina.verey@shopify.com>
This commit is contained in:
Cailyn
2023-02-01 14:25:37 -05:00
committed by GitHub
parent 9d8ed39d3d
commit 95edcc0681
8 changed files with 151 additions and 36 deletions

View File

@@ -75,7 +75,8 @@ $(MYGOBIN)/pluginator:
# Build from local source.
$(MYGOBIN)/kustomize: build-kustomize-api
cd kustomize; \
go install .
go install -ldflags "-X sigs.k8s.io/kustomize/api/provenance.buildDate=$(shell date -u +'%Y-%m-%dT%H:%M:%SZ')" \
.
kustomize: $(MYGOBIN)/kustomize