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 307278c14e53 chore: handle any Antora version qualifier in xref-check
307278c14e53 is described below

commit 307278c14e532b0282c52554330b72e52d9085b6
Author: Claus Ibsen <[email protected]>
AuthorDate: Thu Jun 25 10:07:31 2026 +0200

    chore: handle any Antora version qualifier in xref-check
    
    Generalize the VERSION@ prefix stripping in XRefCheckMojo from only
    handling latest@ to any version qualifier (e.g. next@). This is needed
    when cross-component xrefs target pages that only exist on a specific
    branch version.
    
    Co-Authored-By: Claude <[email protected]>
    Signed-off-by: Claus Ibsen <[email protected]>
---
 .../main/java/org/apache/camel/maven/packaging/XRefCheckMojo.java    | 5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)

diff --git 
a/tooling/maven/camel-package-maven-plugin/src/main/java/org/apache/camel/maven/packaging/XRefCheckMojo.java
 
b/tooling/maven/camel-package-maven-plugin/src/main/java/org/apache/camel/maven/packaging/XRefCheckMojo.java
index a0becc476791..b2549edbc938 100644
--- 
a/tooling/maven/camel-package-maven-plugin/src/main/java/org/apache/camel/maven/packaging/XRefCheckMojo.java
+++ 
b/tooling/maven/camel-package-maven-plugin/src/main/java/org/apache/camel/maven/packaging/XRefCheckMojo.java
@@ -157,8 +157,9 @@ public class XRefCheckMojo extends AbstractMojo {
                     ml = module;
                     rem = groups[0];
                 }
-                if (cl.startsWith("latest@")) {
-                    cl = cl.substring("latest@".length());
+                int at = cl.indexOf('@');
+                if (at >= 0) {
+                    cl = cl.substring(at + 1);
                 }
                 link = cl + ":" + ml + ":" + rem;
                 if (!pages.containsKey(link)) {

Reply via email to