From c598d79462a4b6c74a146f3bf884518ae7eb8948 Mon Sep 17 00:00:00 2001 From: ltheussl Date: Sun, 23 Oct 2005 23:45:23 +0000 Subject: [PATCH] MPXDOC-164: Add a sitemap git-svn-id: https://svn.apache.org/repos/asf/maven/maven-1/plugins/trunk@327884 13f79535-47bb-0310-9956-ffa450edef68 --- xdoc/plugin.jelly | 40 +++++ xdoc/src/plugin-resources/sitemap.jsl | 149 ++++++++++++++++++ .../templates/templates.properties | 4 + .../templates/templates_de.properties | 4 + .../templates/templates_fr.properties | 4 + .../xsd/maven-navigation-1.10.xsd | 2 + .../plugin-test/test04/xdocs/navigation.xml | 8 +- xdoc/src/xsd/maven-navigation.xsd | 2 + xdoc/xdocs/changes.xml | 1 + xdoc/xdocs/goals.xml | 8 + xdoc/xdocs/navigation.xml | 2 + xdoc/xdocs/reference/navfile.xml | 21 +++ 12 files changed, 241 insertions(+), 4 deletions(-) create mode 100644 xdoc/src/plugin-resources/sitemap.jsl diff --git a/xdoc/plugin.jelly b/xdoc/plugin.jelly index a757775f..38ea23c9 100644 --- a/xdoc/plugin.jelly +++ b/xdoc/plugin.jelly @@ -719,6 +719,11 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/xdoc/src/plugin-resources/sitemap.jsl b/xdoc/src/plugin-resources/sitemap.jsl new file mode 100644 index 00000000..1c72f1d1 --- /dev/null +++ b/xdoc/src/plugin-resources/sitemap.jsl @@ -0,0 +1,149 @@ + + + + + + + + + + <message key="sitemap.title" + bundle="plugin-resources.templates.templates" /> + + + + +
+ + +
+ +
+
+ + + + + + + + + + + + + + + + + + + + + + +
  • + + ${description} + + + + + + + + + + + + ${description} + +
  • +
    + +
  • + + ${description} + + + + + + + + + + + + ${description} + +
      + +
    +
  • +
    +
    +
    + + + + + + + + + + + + + + + +
    diff --git a/xdoc/src/plugin-resources/templates/templates.properties b/xdoc/src/plugin-resources/templates/templates.properties index 4f9d38ee..bee1b7f0 100644 --- a/xdoc/src/plugin-resources/templates/templates.properties +++ b/xdoc/src/plugin-resources/templates/templates.properties @@ -167,3 +167,7 @@ site.description=Description site.navbar.previous=previous site.navbar.home=home site.navbar.next=next + +# For sitemap.jsl +sitemap.title=Sitemap +sitemap.section.title=Sitemap diff --git a/xdoc/src/plugin-resources/templates/templates_de.properties b/xdoc/src/plugin-resources/templates/templates_de.properties index f42bbce9..0ea813e9 100644 --- a/xdoc/src/plugin-resources/templates/templates_de.properties +++ b/xdoc/src/plugin-resources/templates/templates_de.properties @@ -169,3 +169,7 @@ site.description=Beschreibung site.navbar.previous=zurück site.navbar.home=Übersicht site.navbar.next=weiter + +# For sitemap.jsl +sitemap.title=Site Map +sitemap.section.title=Site Map diff --git a/xdoc/src/plugin-resources/templates/templates_fr.properties b/xdoc/src/plugin-resources/templates/templates_fr.properties index 1eec50ea..f3c9a48d 100644 --- a/xdoc/src/plugin-resources/templates/templates_fr.properties +++ b/xdoc/src/plugin-resources/templates/templates_fr.properties @@ -169,3 +169,7 @@ site.description=Description site.navbar.previous=précédent site.navbar.home=Accueil site.navbar.next=suivant + +# For sitemap.jsl +sitemap.title=Plan du site +sitemap.section.title=Plan du site diff --git a/xdoc/src/plugin-resources/xsd/maven-navigation-1.10.xsd b/xdoc/src/plugin-resources/xsd/maven-navigation-1.10.xsd index 1c0f414b..381d6057 100644 --- a/xdoc/src/plugin-resources/xsd/maven-navigation-1.10.xsd +++ b/xdoc/src/plugin-resources/xsd/maven-navigation-1.10.xsd @@ -40,6 +40,7 @@ + @@ -47,6 +48,7 @@ + diff --git a/xdoc/src/plugin-test/test04/xdocs/navigation.xml b/xdoc/src/plugin-test/test04/xdocs/navigation.xml index 69b9b889..3743efcd 100644 --- a/xdoc/src/plugin-test/test04/xdocs/navigation.xml +++ b/xdoc/src/plugin-test/test04/xdocs/navigation.xml @@ -30,14 +30,14 @@ img="images/pdf.gif"/> --> - + - - + diff --git a/xdoc/src/xsd/maven-navigation.xsd b/xdoc/src/xsd/maven-navigation.xsd index 1c0f414b..381d6057 100644 --- a/xdoc/src/xsd/maven-navigation.xsd +++ b/xdoc/src/xsd/maven-navigation.xsd @@ -40,6 +40,7 @@ + @@ -47,6 +48,7 @@ + diff --git a/xdoc/xdocs/changes.xml b/xdoc/xdocs/changes.xml index f2896df4..57c00756 100644 --- a/xdoc/xdocs/changes.xml +++ b/xdoc/xdocs/changes.xml @@ -27,6 +27,7 @@ + New goal xdoc:sitemap to generate a sitemap. Update dependencies to match ones in maven 1.1 core and to unify them between plugins. The following dependencies are updated :
    • commons-jelly v1.0-RC1 -> v1.0
    • diff --git a/xdoc/xdocs/goals.xml b/xdoc/xdocs/goals.xml index 830313da..342d620e 100644 --- a/xdoc/xdocs/goals.xml +++ b/xdoc/xdocs/goals.xml @@ -62,6 +62,14 @@ Validates the navigation file ${maven.xdoc.navigation.file}. + + xdoc:sitemap + + Generates a sitemap from the information found in the + navigation file ${maven.xdoc.navigation.file}. + See Sitemap. + + copy-user-bundles diff --git a/xdoc/xdocs/navigation.xml b/xdoc/xdocs/navigation.xml index a25fac01..1c380390 100644 --- a/xdoc/xdocs/navigation.xml +++ b/xdoc/xdocs/navigation.xml @@ -30,7 +30,9 @@ + + diff --git a/xdoc/xdocs/reference/navfile.xml b/xdoc/xdocs/reference/navfile.xml index 456fac45..3675b03c 100644 --- a/xdoc/xdocs/reference/navfile.xml +++ b/xdoc/xdocs/reference/navfile.xml @@ -20,6 +20,9 @@ Navigation + + +

      @@ -43,6 +46,7 @@ . +

      . @@ -76,6 +80,23 @@

      + +

      + If a <sitemap/> element is found in the + navigation.xml body, a sitemap.html + file is generated. An optional description + is added for a page if a <meta> element is + found in the corresponding xdoc source document header: +

      + + +]]> +

      + See the sitemap + of the current site for an example. +

      +
      +

      The <menu> element takes an optional