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

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


The following commit(s) were added to refs/heads/main by this push:
     new 3e5c1fcf1e2 camel-jbang - Polished
3e5c1fcf1e2 is described below

commit 3e5c1fcf1e231f62a9f0462438df143d4364ca2a
Author: Claus Ibsen <claus.ib...@gmail.com>
AuthorDate: Thu Sep 22 09:42:29 2022 +0200

    camel-jbang - Polished
---
 .../camel/dsl/jbang/core/commands/catalog/CatalogBaseCommand.java   | 6 +++---
 .../camel/dsl/jbang/core/commands/catalog/CatalogKamelet.java       | 4 ++--
 2 files changed, 5 insertions(+), 5 deletions(-)

diff --git 
a/dsl/camel-jbang/camel-jbang-core/src/main/java/org/apache/camel/dsl/jbang/core/commands/catalog/CatalogBaseCommand.java
 
b/dsl/camel-jbang/camel-jbang-core/src/main/java/org/apache/camel/dsl/jbang/core/commands/catalog/CatalogBaseCommand.java
index d0f02f4febe..e5cdf93b606 100644
--- 
a/dsl/camel-jbang/camel-jbang-core/src/main/java/org/apache/camel/dsl/jbang/core/commands/catalog/CatalogBaseCommand.java
+++ 
b/dsl/camel-jbang/camel-jbang-core/src/main/java/org/apache/camel/dsl/jbang/core/commands/catalog/CatalogBaseCommand.java
@@ -39,7 +39,7 @@ public abstract class CatalogBaseCommand extends CamelCommand 
{
     String sort;
 
     @CommandLine.Option(names = { "--gav" },
-                        description = "Include column with Maven GAV", 
defaultValue = "false")
+                        description = "Display Maven GAV instead of name", 
defaultValue = "false")
     boolean gav;
 
     @CommandLine.Option(names = { "--filter" },
@@ -75,9 +75,9 @@ public abstract class CatalogBaseCommand extends CamelCommand 
{
 
         if (!rows.isEmpty()) {
             System.out.println(AsciiTable.getTable(AsciiTable.NO_BORDERS, 
rows, Arrays.asList(
-                    new 
Column().header("NAME").dataAlign(HorizontalAlign.LEFT).with(r -> r.name),
+                    new 
Column().header("NAME").visible(!gav).dataAlign(HorizontalAlign.LEFT).with(r -> 
r.name),
                     new 
Column().header("ARTIFACT-ID").visible(gav).dataAlign(HorizontalAlign.LEFT).with(this::shortGav),
-                    new 
Column().header("LEVEL").dataAlign(HorizontalAlign.LEFT).with(r -> r.level),
+                    new 
Column().header("LEVEL").dataAlign(HorizontalAlign.LEFT).minWidth(12).with(r -> 
r.level),
                     new 
Column().header("DESCRIPTION").dataAlign(HorizontalAlign.LEFT).with(this::shortDescription))));
         }
 
diff --git 
a/dsl/camel-jbang/camel-jbang-core/src/main/java/org/apache/camel/dsl/jbang/core/commands/catalog/CatalogKamelet.java
 
b/dsl/camel-jbang/camel-jbang-core/src/main/java/org/apache/camel/dsl/jbang/core/commands/catalog/CatalogKamelet.java
index 5c35c5b1d35..faef90d6a51 100644
--- 
a/dsl/camel-jbang/camel-jbang-core/src/main/java/org/apache/camel/dsl/jbang/core/commands/catalog/CatalogKamelet.java
+++ 
b/dsl/camel-jbang/camel-jbang-core/src/main/java/org/apache/camel/dsl/jbang/core/commands/catalog/CatalogKamelet.java
@@ -102,8 +102,8 @@ public class CatalogKamelet extends CamelCommand {
         if (!rows.isEmpty()) {
             System.out.println(AsciiTable.getTable(AsciiTable.NO_BORDERS, 
rows, Arrays.asList(
                     new 
Column().header("NAME").dataAlign(HorizontalAlign.LEFT).with(r -> r.name),
-                    new 
Column().header("TYPE").dataAlign(HorizontalAlign.LEFT).with(r -> r.type),
-                    new 
Column().header("LEVEL").dataAlign(HorizontalAlign.LEFT).with(r -> 
r.supportLevel),
+                    new 
Column().header("TYPE").dataAlign(HorizontalAlign.LEFT).minWidth(10).with(r -> 
r.type),
+                    new 
Column().header("LEVEL").dataAlign(HorizontalAlign.LEFT).minWidth(12).with(r -> 
r.supportLevel),
                     new 
Column().header("DESCRIPTION").dataAlign(HorizontalAlign.LEFT).with(this::getDescription))));
         }
 

Reply via email to