You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@camel.apache.org by pc...@apache.org on 2022/06/16 07:30:56 UTC

[camel-k] branch main updated: Fixes GIT_COMMIT assignment failure in build

This is an automated email from the ASF dual-hosted git repository.

pcongiusti pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/camel-k.git


The following commit(s) were added to refs/heads/main by this push:
     new e344be85e Fixes GIT_COMMIT assignment failure in build
e344be85e is described below

commit e344be85e911fc3da452f5ea6552821695710f40
Author: phantomjinx <p....@phantomjinx.co.uk>
AuthorDate: Mon Jun 6 19:42:53 2022 +0100

    Fixes GIT_COMMIT assignment failure in build
---
 script/Makefile | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/script/Makefile b/script/Makefile
index a7e7c1411..635f3265c 100644
--- a/script/Makefile
+++ b/script/Makefile
@@ -43,7 +43,7 @@ CUSTOM_VERSION ?= $(VERSION)
 METADATA_IMAGE_NAME := $(CUSTOM_IMAGE)-metadata
 BUNDLE_IMAGE_NAME ?= $(CUSTOM_IMAGE)-bundle
 RELEASE_GIT_REMOTE := origin
-GIT_COMMIT := $(shell git rev-list -1 HEAD)
+GIT_COMMIT := $(shell if [ -d .git ]; then git rev-list -1 HEAD; else echo "$(CUSTOM_VERSION)"; fi)
 LINT_GOGC := 10
 LINT_DEADLINE := 10m