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 2023/04/28 08:20:34 UTC

[camel-k] branch main updated: fix: align process to latest ck runtime changes

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 32527c10f fix: align process to latest ck runtime changes
32527c10f is described below

commit 32527c10f86d96f1eb2b58773b85e4420e4ee594
Author: Pasquale Congiusti <pa...@gmail.com>
AuthorDate: Thu Apr 27 13:33:56 2023 +0200

    fix: align process to latest ck runtime changes
---
 script/update_default_camel.sh | 8 +++++---
 1 file changed, 5 insertions(+), 3 deletions(-)

diff --git a/script/update_default_camel.sh b/script/update_default_camel.sh
index 796e528cc..c64657bc2 100755
--- a/script/update_default_camel.sh
+++ b/script/update_default_camel.sh
@@ -21,16 +21,18 @@ set -e
 
 location=$(dirname $0)
 
+rm -rf /tmp/camel-k-runtime
 git clone --depth 1 https://github.com/apache/camel-k-runtime.git /tmp/camel-k-runtime
 ck_runtime_version=$(mvn help:evaluate -Dexpression=project.version -q -DforceStdout -f /tmp/camel-k-runtime/pom.xml)
 echo "INFO: last Camel K runtime version set at $ck_runtime_version"
 sed -i "s/^RUNTIME_VERSION := .*$/RUNTIME_VERSION := $ck_runtime_version/" $location/Makefile
+camel_version=$(grep -oPm1 "(?<=<camel-version>)[^<]+" /tmp/camel-k-runtime/pom.xml)
 
+rm -rf /tmp/camel-kamelets
 git clone https://github.com/apache/camel-kamelets.git /tmp/camel-kamelets
 pushd /tmp/camel-kamelets
-ck_camel_base_version=$(echo "$ck_runtime_version" | sed -r 's/-SNAPSHOT//g')
-echo "INFO: Looking a suitable Kamelet tag for $ck_camel_base_version camel version"
-kamelets_tag=$(git tag | grep $ck_camel_base_version | sort -r | head -n 1)
+echo "INFO: Looking a suitable Kamelet tag for $camel_version camel version"
+kamelets_tag=$(git tag | grep $camel_version | sort -r | head -n 1)
 popd
 echo "INFO: Kamelets version set at $kamelets_tag"
 sed -i "s/^KAMELET_CATALOG_REPO_TAG := .*$/KAMELET_CATALOG_REPO_TAG := $kamelets_tag/" $location/Makefile