Guillaume Nodet created CAMEL-23303:
---------------------------------------
Summary: Fix JBang metadata generation to detect all commands and
resolve completion candidates
Key: CAMEL-23303
URL: https://issues.apache.org/jira/browse/CAMEL-23303
Project: Camel
Issue Type: Bug
Reporter: Guillaume Nodet
Fix For: 4.19.0
The PrepareCamelJBangCommandsMojo has several issues:
1. It only detects commands that are direct inner classes of CamelJBangMain,
missing commands registered via addCommand() calls (e.g. wrapper, transform
dataweave).
2. Picocli completion candidates (e.g. \$\{COMPLETION-CANDIDATES\}) are not
resolved in the generated documentation, showing raw placeholders instead of
actual values.
3. The docs gulp resilientSrc function processes all glob patterns as a single
stream, so an ENOENT in one pattern aborts all patterns.
This fix:
- Enhances the mojo to scan for addCommand() calls and resolve the referenced
command classes
- Resolves picocli completion candidate placeholders by instantiating the
completionCandidates class
- Processes each glob pattern independently in resilientSrc so failures are
isolated
--
This message was sent by Atlassian Jira
(v8.20.10#820010)