From 674bfaa0f474c7ad4cb1636338473278f8a87c73 Mon Sep 17 00:00:00 2001 From: Vincent Siveton Date: Fri, 29 Jul 2005 11:49:47 +0000 Subject: [PATCH] Refactor the maven-site.vm: added a macro to handle the copyright git-svn-id: https://svn.apache.org/repos/asf/maven/components/trunk@226349 13f79535-47bb-0310-9956-ffa450edef68 --- .../org/apache/maven/doxia/maven-site.vm | 40 ++++++++++--------- 1 file changed, 21 insertions(+), 19 deletions(-) diff --git a/maven-plugins/maven-site-plugin/src/main/resources/org/apache/maven/doxia/maven-site.vm b/maven-plugins/maven-site-plugin/src/main/resources/org/apache/maven/doxia/maven-site.vm index 5f12d54844..174e942773 100644 --- a/maven-plugins/maven-site-plugin/src/main/resources/org/apache/maven/doxia/maven-site.vm +++ b/maven-plugins/maven-site-plugin/src/main/resources/org/apache/maven/doxia/maven-site.vm @@ -106,6 +106,26 @@ #end #end +#macro ( copyright ) + #if ( $project ) + #set ( $currentYear = ${currentDate.year} + 1900 ) + + #if ( ${project.inceptionYear} && ( ${project.inceptionYear} != ${currentYear.toString()} ) ) + ${project.inceptionYear}-${currentYear} + #else + ${currentYear} + #end + + #if ( ${project.organization} && ${project.organization.name} ) + ${project.organization.name} + #else + Apache Software Foundation + #end + #else + 2002-2005, Apache Software Foundation + #end +#end + @@ -151,25 +171,7 @@