We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents d62cbff + a15f0c1 commit 12ece37Copy full SHA for 12ece37
Makefile
@@ -3,6 +3,8 @@ export GO15VENDOREXPERIMENT
3
PREFIX ?= $(DESTDIR)/usr
4
BINDIR ?= $(DESTDIR)/usr/bin
5
6
+COMMIT=$(shell git rev-parse HEAD 2> /dev/null || true)
7
+EPOCH_TEST_COMMIT ?= $(shell git tag | tail -1)
8
9
default: all
10
@@ -27,7 +29,7 @@ check-license:
27
29
28
30
.PHONY: tool
31
tool:
- go build -o oci-image-tool ./cmd/oci-image-tool
32
+ go build -ldflags "-X main.gitCommit=${COMMIT}" -o oci-image-tool ./cmd/oci-image-tool
33
34
35
all: tool man
0 commit comments