From 87de0259e572ff336ab74b297997bc9d774c346b Mon Sep 17 00:00:00 2001 From: filip Date: Wed, 28 Feb 2024 00:34:56 +0100 Subject: [PATCH 1/3] Fix makefile --- Makefile | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/Makefile b/Makefile index d3d0fce9c1..6b1d2ae4d4 100644 --- a/Makefile +++ b/Makefile @@ -42,10 +42,10 @@ build: check-go check-git $(eval BRANCH = $(shell git rev-parse --abbrev-ref HEAD | tr -d '\040\011\012\015\n')) $(eval TIME = $(shell date)) go build -o blade -ldflags="\ - -X 'github.com/Ethernal-Tech/blade/versioning.Version=$(VERSION)' \ - -X 'github.com/Ethernal-Tech/blade/versioning.Commit=$(COMMIT_HASH)'\ - -X 'github.com/Ethernal-Tech/blade/versioning.Branch=$(BRANCH)'\ - -X 'github.com/Ethernal-Tech/blade/versioning.BuildTime=$(TIME)'" \ + -X 'github.com/0xPolygon/polygon-edge/versioning.Version=$(VERSION)' \ + -X 'github.com/0xPolygon/polygon-edge/versioning.Commit=$(COMMIT_HASH)'\ + -X 'github.com/0xPolygon/polygon-edge/versioning.Branch=$(BRANCH)'\ + -X 'github.com/0xPolygon/polygon-edge/versioning.BuildTime=$(TIME)'" \ main.go .PHONY: lint From 62558946c839dd190528baad82d94fb1e5906f03 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Stefan=20Negovanovi=C4=87?= Date: Wed, 28 Feb 2024 10:22:52 +0100 Subject: [PATCH 2/3] Find the latest tag compared to the current commit --- Makefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Makefile b/Makefile index 6b1d2ae4d4..84aad2aa55 100644 --- a/Makefile +++ b/Makefile @@ -38,7 +38,7 @@ protoc: check-protoc .PHONY: build build: check-go check-git $(eval COMMIT_HASH = $(shell git rev-parse HEAD)) - $(eval VERSION = $(shell git tag --points-at ${COMMIT_HASH})) + $(eval VERSION = $(shell git describe --tags --abbrev=0 ${COMMIT_HASH})) $(eval BRANCH = $(shell git rev-parse --abbrev-ref HEAD | tr -d '\040\011\012\015\n')) $(eval TIME = $(shell date)) go build -o blade -ldflags="\ From 31c99359bdaa19fb44ce40ef05648290a59da3cc Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Stefan=20Negovanovi=C4=87?= Date: Wed, 28 Feb 2024 10:26:25 +0100 Subject: [PATCH 3/3] Indentation fix --- Makefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Makefile b/Makefile index 84aad2aa55..9a8c5de0af 100644 --- a/Makefile +++ b/Makefile @@ -42,7 +42,7 @@ build: check-go check-git $(eval BRANCH = $(shell git rev-parse --abbrev-ref HEAD | tr -d '\040\011\012\015\n')) $(eval TIME = $(shell date)) go build -o blade -ldflags="\ - -X 'github.com/0xPolygon/polygon-edge/versioning.Version=$(VERSION)' \ + -X 'github.com/0xPolygon/polygon-edge/versioning.Version=$(VERSION)' \ -X 'github.com/0xPolygon/polygon-edge/versioning.Commit=$(COMMIT_HASH)'\ -X 'github.com/0xPolygon/polygon-edge/versioning.Branch=$(BRANCH)'\ -X 'github.com/0xPolygon/polygon-edge/versioning.BuildTime=$(TIME)'" \