From 8ad51a157348aad520bc559b0404c7e16188830a Mon Sep 17 00:00:00 2001 From: Kai Moritz Date: Sat, 25 Oct 2025 09:46:33 +0200 Subject: [PATCH] Added a parameter "flat" to generate all links as canonical links --- src/main/resources/META-INF/maven/site.vm | 7 ++++++- src/site/xhtml/usage.xhtml | 7 +++++++ 2 files changed, 13 insertions(+), 1 deletion(-) diff --git a/src/main/resources/META-INF/maven/site.vm b/src/main/resources/META-INF/maven/site.vm index b4866d1..46d0a3a 100644 --- a/src/main/resources/META-INF/maven/site.vm +++ b/src/main/resources/META-INF/maven/site.vm @@ -127,7 +127,12 @@ #set ( $canonicalPath = "" ) #end -#set ( $sitePath = $pathPrefix + $canonicalPath + $project.version + "/" ) +#if ( $decoration.custom.getChild( 'thymeproxy' ).getChild( 'flat' ).getValue() ) + + #set ( $sitePath = $canonicalPath ) +#else + #set ( $sitePath = $pathPrefix + $canonicalPath + $project.version + "/" ) +#end #set ( $siteCrumbs = $decoration.custom.getChild( 'thymeproxy' ).getChild( 'crumbs' ).getValue() ) #set ( $command = $decoration.custom.getChild( 'thymeproxy' ).getChild( 'command' ).getValue() ) #if ( !$command ) diff --git a/src/site/xhtml/usage.xhtml b/src/site/xhtml/usage.xhtml index 48d4a82..0a208f1 100644 --- a/src/site/xhtml/usage.xhtml +++ b/src/site/xhtml/usage.xhtml @@ -27,6 +27,7 @@ @@ -49,6 +50,12 @@

prefix

If set, the path is prefixed with the value, when generating the site_uri.

+

flat

+

+ If set, the configuration properties prefix and path are ignored, + when generating the site_uri. + Thus, the generated site_uri is always equal to the generated canonical_uri. +

crumbs

Some crumbs, that should be prepended to the breadcrumbs that are computed for the pages.

The crumbs have to be specified in double quotes and must be separated by commas. Example:

-- 2.39.5