You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@camel.apache.org by as...@apache.org on 2019/10/30 12:14:54 UTC

[camel-k-runtime] 08/09: feat(quarkus): Better catalog name with runtime provider

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

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

commit 5351275f221ec31cb9f2db18583a6e06df1305c8
Author: Antonin Stefanutti <an...@stefanutti.fr>
AuthorDate: Tue Oct 29 18:47:00 2019 +0100

    feat(quarkus): Better catalog name with runtime provider
---
 .../camel/k/tooling/maven/GenerateCatalogMojo.java      | 17 +++++++++++++----
 1 file changed, 13 insertions(+), 4 deletions(-)

diff --git a/tooling/camel-k-maven-plugin/src/main/java/org/apache/camel/k/tooling/maven/GenerateCatalogMojo.java b/tooling/camel-k-maven-plugin/src/main/java/org/apache/camel/k/tooling/maven/GenerateCatalogMojo.java
index a103120..e536ba5 100644
--- a/tooling/camel-k-maven-plugin/src/main/java/org/apache/camel/k/tooling/maven/GenerateCatalogMojo.java
+++ b/tooling/camel-k-maven-plugin/src/main/java/org/apache/camel/k/tooling/maven/GenerateCatalogMojo.java
@@ -150,10 +150,19 @@ public class GenerateCatalogMojo extends AbstractMojo {
             //   artifacts:
             //
             try (Writer writer = Files.newBufferedWriter(output, StandardCharsets.UTF_8)) {
-                String catalogName = String.format("camel-catalog-%s-%s",
-                    catalog.getCatalogVersion().toLowerCase(),
-                    getRuntimeVersion().toLowerCase()
-                );
+                String catalogName;
+                if ("quarkus".equals(runtime)) {
+                    catalogName = String.format("camel-%s-catalog-%s-%s",
+                        runtime,
+                        getVersionFor("/META-INF/maven/org.apache.camel.quarkus/camel-catalog-quarkus/pom.properties"),
+                        getRuntimeVersion().toLowerCase()
+                    );
+                } else {
+                    catalogName = String.format("camel-catalog-%s-%s",
+                        catalog.getCatalogVersion().toLowerCase(),
+                        getRuntimeVersion().toLowerCase()
+                    );
+                }
 
                 ObjectMeta.Builder labels = new ObjectMeta.Builder()
                     .name(catalogName)