Author: rgardler
Date: Thu Oct 20 16:12:59 2005
New Revision: 327033
URL: http://svn.apache.org/viewcvs?rev=327033&view=rev
Log:
add some rudimentary indexing. The indexes are created by querying the
locationmap for all project descriptors and collating them together
Modified:
forrest/trunk/plugins/org.apache.forrest.plugin.input.projectInfo/build.xml
forrest/trunk/plugins/org.apache.forrest.plugin.input.projectInfo/doap.rdf
forrest/trunk/plugins/org.apache.forrest.plugin.input.projectInfo/input.xmap
forrest/trunk/plugins/org.apache.forrest.plugin.input.projectInfo/locationmap.xml
forrest/trunk/plugins/org.apache.forrest.plugin.input.projectInfo/src/documentation/content/xdocs/index.xml
forrest/trunk/plugins/org.apache.forrest.plugin.input.projectInfo/src/documentation/content/xdocs/site.xml
Modified:
forrest/trunk/plugins/org.apache.forrest.plugin.input.projectInfo/build.xml
URL:
http://svn.apache.org/viewcvs/forrest/trunk/plugins/org.apache.forrest.plugin.input.projectInfo/build.xml?rev=327033&r1=327032&r2=327033&view=diff
==============================================================================
--- forrest/trunk/plugins/org.apache.forrest.plugin.input.projectInfo/build.xml
(original)
+++ forrest/trunk/plugins/org.apache.forrest.plugin.input.projectInfo/build.xml
Thu Oct 20 16:12:59 2005
@@ -20,7 +20,7 @@
<property name="plugin-name"
value="org.apache.forrest.plugin.input.projectInfo"/>
<property name="forrest.version" value="0.8"/>
<property name="type" value="input"/>
- <property name="plugin-version" value="0.2"/>
+ <property name="plugin-version" value="0.3-dev"/>
<property name="description" value="Generates project info such as changelog
and todo list. "/>
<property name="author" value="Apache Forrest Project"/>
<property name="websiteURL"
value="http://forrest.apache.org/docs/plugins/org.apache.forrest.plugin.input.projectInfo/"/>
Modified:
forrest/trunk/plugins/org.apache.forrest.plugin.input.projectInfo/doap.rdf
URL:
http://svn.apache.org/viewcvs/forrest/trunk/plugins/org.apache.forrest.plugin.input.projectInfo/doap.rdf?rev=327033&r1=327032&r2=327033&view=diff
==============================================================================
--- forrest/trunk/plugins/org.apache.forrest.plugin.input.projectInfo/doap.rdf
(original)
+++ forrest/trunk/plugins/org.apache.forrest.plugin.input.projectInfo/doap.rdf
Thu Oct 20 16:12:59 2005
@@ -12,9 +12,8 @@
<doap:shortdesc>Automatically generate Project Information
files.</doap:shortdesc>
<doap:bug-database
rdf:resource="http://issues.apache.org/jira/browse/FOR"/>
<doap:mailing-list
rdf:resource="http://forrest.apache.org/mail-lists.html"/>
- <doap:programming-language>java</doap:programming-language>
- <doap:programming-language>xml</doap:programming-language>
- <doap:programming-language>xslt</doap:programming-language>
+ <doap:programming-language>XML</doap:programming-language>
+ <doap:programming-language>XSLT</doap:programming-language>
<doap:license rdf:resource="http://usefulinc.com/doap/licenses/asl20"/>
<doap:download-page
rdf:resource="http://forrest.apache.org/pluginDocs/plugins_0_80/index.html"/>
<doap:maintainer>
Modified:
forrest/trunk/plugins/org.apache.forrest.plugin.input.projectInfo/input.xmap
URL:
http://svn.apache.org/viewcvs/forrest/trunk/plugins/org.apache.forrest.plugin.input.projectInfo/input.xmap?rev=327033&r1=327032&r2=327033&view=diff
==============================================================================
---
forrest/trunk/plugins/org.apache.forrest.plugin.input.projectInfo/input.xmap
(original)
+++
forrest/trunk/plugins/org.apache.forrest.plugin.input.projectInfo/input.xmap
Thu Oct 20 16:12:59 2005
@@ -17,6 +17,9 @@
-->
<map:sitemap xmlns:map="http://apache.org/cocoon/sitemap/1.0">
<map:components>
+ <map:transformers default="xslt">
+ <map:transformer name="cinclude"
src="org.apache.cocoon.transformation.CIncludeTransformer"/>
+ </map:transformers>
<map:serializers default="html">
<map:serializer name="rss091" mime-type="text/xml"
src="org.apache.cocoon.serialization.XMLSerializer">
<doctype-public>-//Netscape Communications//DTD RSS
0.91//EN</doctype-public>
@@ -28,6 +31,17 @@
<map:pipelines>
<map:pipeline>
+
+ <map:match pattern="projectDetails.source.xml">
+ <map:generate type="file" src="{lm:project.descriptor}" />
+ <map:serialize type="xml-document"/>
+ </map:match>
+
+ <map:match pattern="projectDetails.*.source.xml">
+ <map:generate type="file" src="{lm:project.descriptor.{1}}" />
+ <map:serialize type="xml-document"/>
+ </map:match>
+
<map:match type="regexp" pattern="^(.*?)([^/]*)changes.xml$">
<map:generate type="file" src="{project:status}" />
@@ -79,11 +93,6 @@
<map:serialize type="xml-document"/>
</map:match>
- <map:match pattern="projectDetails.source.xml">
- <map:generate type="file" src="{lm:projectInfo.project.descriptor}" />
- <map:serialize type="xml-document"/>
- </map:match>
-
<map:match pattern="projectDetails.*.xml">
<map:generate type="file" src="{lm:project.descriptor.{1}}" />
<map:transform src="{lm:projectInfo.transform.doap.html}"/>
@@ -91,8 +100,40 @@
<map:serialize type="xml-document"/>
</map:match>
- <map:match pattern="projectDetails.*.source.xml">
- <map:generate type="file" src="{lm:project.descriptor.{1}}" />
+ <map:match pattern="projectDetails/index.xml">
+ <map:generate type="file" src="locationmap-projects.xml" />
+ <map:transform
src="{lm:projectInfo.transform.locationmap.descriptorIndex}"/>
+ <map:transform type="cinclude"/>
+ <!--<map:transform
src="{lm:projectInfo.transform.descriptorIndex.html}"/>-->
+ <map:serialize type="xml-document"/>
+ </map:match>
+
+
+ <!--
+ Create a snippet for inclusion in site.xml that lists all projects
+ known in the locationmap-projects.xml file.
+ -->
+ <map:match pattern="projectDetails/index.siteSnippet.xml">
+ <map:generate type="file" src="locationmap.xml" />
+ <map:transform
src="{lm:projectInfo.transform.locationmap.descriptorIndex}"/>
+ <map:transform type="cinclude"/>
+ <map:transform
src="{lm:projectInfo.transform.descriptorIndex.siteSnippet}"/>
+ <map:serialize type="xml-document"/>
+ </map:match>
+
+ <!--
+ Create a snippet for inclusion in site.xml that lists all projects
+ known in the locationmap-projects.xml that have the indicated
+ programming language.
+ -->
+ <map:match pattern="projectDetails/language-*/index.siteSnippet.xml">
+ <map:generate type="file" src="locationmap.xml" />
+ <map:transform
src="{lm:projectInfo.transform.locationmap.descriptorIndex}"/>
+ <map:transform type="cinclude"/>
+ <map:transform
src="{lm:projectInfo.transform.descriptorIndex.siteSnippet}">
+ <map:parameter name="name" value="{1}"/>
+ <map:parameter name="progLanguage" value="{1}"/>
+ </map:transform>
<map:serialize type="xml-document"/>
</map:match>
Modified:
forrest/trunk/plugins/org.apache.forrest.plugin.input.projectInfo/locationmap.xml
URL:
http://svn.apache.org/viewcvs/forrest/trunk/plugins/org.apache.forrest.plugin.input.projectInfo/locationmap.xml?rev=327033&r1=327032&r2=327033&view=diff
==============================================================================
---
forrest/trunk/plugins/org.apache.forrest.plugin.input.projectInfo/locationmap.xml
(original)
+++
forrest/trunk/plugins/org.apache.forrest.plugin.input.projectInfo/locationmap.xml
Thu Oct 20 16:12:59 2005
@@ -33,17 +33,23 @@
</components>
<locator>
-
- <match pattern="project.status">
- <location src="{project:status}" />
- </match>
-
+
<match pattern="project.descriptor">
<location src="doap.rdf" />
- </match>
+ </match>
<match pattern="project.descriptor.forrest">
<location
src="http://svn.apache.org/repos/asf/forrest/trunk/site-author/content/doap.xml"/>
+ </match>
+
+ <!-- The DOAP is not embedded in an rdf element so is not currently
working properly.
+
+ <match pattern="project.descriptor.doap">
+ <location
src="http://svn.usefulinc.com/svn/repos/trunk/doap/examples/doap-doap.rdf"/>
+ </match>
+ -->
+ <match pattern="project.status">
+ <location src="{project:status}" />
</match>
<match pattern="projectInfo.transform.*.*">
Modified:
forrest/trunk/plugins/org.apache.forrest.plugin.input.projectInfo/src/documentation/content/xdocs/index.xml
URL:
http://svn.apache.org/viewcvs/forrest/trunk/plugins/org.apache.forrest.plugin.input.projectInfo/src/documentation/content/xdocs/index.xml?rev=327033&r1=327032&r2=327033&view=diff
==============================================================================
---
forrest/trunk/plugins/org.apache.forrest.plugin.input.projectInfo/src/documentation/content/xdocs/index.xml
(original)
+++
forrest/trunk/plugins/org.apache.forrest.plugin.input.projectInfo/src/documentation/content/xdocs/index.xml
Thu Oct 20 16:12:59 2005
@@ -77,14 +77,15 @@
with the hint <code>pproject.descriptor</code>. This defaults to
the root of your projects content directory. To place your descriptor
in a different location simply add
- a matcher like this to your project locationmap:</p>
+ a matcher like that shown below in your
<code>projectInfo.locationmap-projects</code>
+ file. This file is, by default, in the root of the webapp directory.</p>
<source><![CDATA[
<match pattern="project.descriptor">
<location src="[path/to/descriptor/file]" />
</match>
]]></source>
-
+
<p>To retrieve the project details page request the file
<code>/projectDetails.html</code>.</p>
@@ -119,6 +120,16 @@
</match>
]]></source>
+ <warning>The indexing of projects (described below) does not currently
work with
+ wildcard matchers in the locationmap.</warning>
+
+ </section>
+
+ <section>
+ <title>Project Indexes</title>
+ <p>The system will automatically create an index of projects from your
+ projects locationmap file. For example, the "Projects" section of the
+ navigation on the left is automatically generated.</p>
</section>
</section>
Modified:
forrest/trunk/plugins/org.apache.forrest.plugin.input.projectInfo/src/documentation/content/xdocs/site.xml
URL:
http://svn.apache.org/viewcvs/forrest/trunk/plugins/org.apache.forrest.plugin.input.projectInfo/src/documentation/content/xdocs/site.xml?rev=327033&r1=327032&r2=327033&view=diff
==============================================================================
---
forrest/trunk/plugins/org.apache.forrest.plugin.input.projectInfo/src/documentation/content/xdocs/site.xml
(original)
+++
forrest/trunk/plugins/org.apache.forrest.plugin.input.projectInfo/src/documentation/content/xdocs/site.xml
Thu Oct 20 16:12:59 2005
@@ -30,24 +30,28 @@
See http://forrest.apache.org/docs/linking.html for more info
-->
-<site label="org.apache.forrest.plugin.input.projectInfo" href=""
xmlns="http://apache.org/forrest/linkmap/1.0" tab="">
+<site label="org.apache.forrest.plugin.input.projectInfo" href="" tab=""
+ xmlns="http://apache.org/forrest/linkmap/1.0"
+ xmlns:xi="http://www.w3.org/2001/XInclude"
+ >
<about label="About">
<index label="Index" href="index.html" description="Welcome to
org.apache.forrest.plugin.input.projectInfo"/>
- <details label="Project Details" href="projectDetails.html"
description="An overview of the project and its resources"/>
<release label="Release Notes">
<releaseNotes label="Version 0.1" href="releaseNotes_0.1.html"/>
<releaseNotes label="Version 0.2" href="releaseNotes_0.2.html"/>
</release>
<changes label="Changes" href="changes.html" description="History of
Changes" />
<todo label="Todo" href="todo.html" description="Todo List" />
+
+ <forrestPlugins label="Plugins Index" href="site:forrest/plugins"
description="Index of Forrest Plugins"/>
</about>
- <forrest label="Forrest">
- <forrestDetails label="Forrest Details" href="projectDetails.forrest.html"
description="An overview of the Forrest project and its resources"/>
- <forrestPlugins label="Plugins Index" href="site:forrest/plugins"
description="Index of Forrest Plugins"/>
- </forrest>
-
+ <projects label="Projects" href="projectDetails/">
+ <xi:include href="cocoon://projectDetails/index.siteSnippet.xml"/>
+ <xi:include
href="cocoon://projectDetails/language-Java/index.siteSnippet.xml"/>
+ </projects>
+
<!--
The href must be wholesite.html/pdf You can change the labels and node names
<all label="All">