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 145afea7796 Try to discover the jsonDir if it is null (#7921)
145afea7796 is described below

commit 145afea7796e55878047b910e37303630d36f619
Author: Tom Cunningham <[email protected]>
AuthorDate: Tue Jun 28 16:03:53 2022 -0400

    Try to discover the jsonDir if it is null (#7921)
---
 .../java/org/apache/camel/maven/packaging/ComponentDslMojo.java   | 8 ++++++--
 1 file changed, 6 insertions(+), 2 deletions(-)

diff --git 
a/tooling/maven/camel-package-maven-plugin/src/main/java/org/apache/camel/maven/packaging/ComponentDslMojo.java
 
b/tooling/maven/camel-package-maven-plugin/src/main/java/org/apache/camel/maven/packaging/ComponentDslMojo.java
index 9ea0147c48d..c3d6ac246c9 100644
--- 
a/tooling/maven/camel-package-maven-plugin/src/main/java/org/apache/camel/maven/packaging/ComponentDslMojo.java
+++ 
b/tooling/maven/camel-package-maven-plugin/src/main/java/org/apache/camel/maven/packaging/ComponentDslMojo.java
@@ -122,8 +122,12 @@ public class ComponentDslMojo extends 
AbstractGeneratorMojo {
         }
 
         if (jsonDir == null) {
-            getLog().debug("No json directory folder found, skipping 
execution");
-            return;
+            jsonDir = findCamelDirectory(baseDir, 
"catalog/camel-catalog/src/generated/resources/org/apache/camel/catalog/components");
+
+            if (jsonDir == null) {
+                getLog().debug("No json directory folder found, skipping 
execution");
+                return;
+            }
         }
 
         Path root = camelDir.toPath();

Reply via email to