You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@forrest.apache.org by is...@cocoondev.org on 2005/05/24 12:19:55 UTC

[JIRA] Updated: (FOR-328) Filesystem Automated Publishing Utility

The following issue has been updated:

    Updater: Ross Gardler (mailto:ross@saafe.org)
       Date: Tue, 24 May 2005 5:19 AM
    Comment:
Reduced priority, we are considering an alternative solution to this as a plugin. Not closing the issue as the attached scripts are useful in the meantime.
    Changes:
             priority changed from Major to Minor
    ---------------------------------------------------------------------
For a full history of the issue, see:

  http://issues.cocoondev.org//browse/FOR-328?page=history

---------------------------------------------------------------------
View the issue:
  http://issues.cocoondev.org//browse/FOR-328

Here is an overview of the issue:
---------------------------------------------------------------------
        Key: FOR-328
    Summary: Filesystem Automated Publishing Utility
       Type: New Feature

     Status: Open
   Priority: Minor

    Project: Forrest

   Assignee: Ross Gardler
   Reporter: Fonzi

    Created: Thu, 21 Oct 2004 9:56 AM
    Updated: Tue, 24 May 2005 5:19 AM
Environment: OS independent, Ant v. 1.6.x, ant-contrib-1.0b1.jar

Description:
We have created an utility written in Ant (see attachment) to automatically build a site using forrest.
The utility automatically create site.xml and tabs.xml based on the given filesystem path, its structure and content.

How we use it:
The real first time we run "forrest seed" as described in <http://forrest.apache.org/docs/your-project.html>
We then make our changes ( in our case we use CVS to check-in our updates and keep the versioning)

A periodic build gets called to upload the latest documentation files (from CVS) and run this utility to create site.xml and tabs.xml necessary to run forrest.

This way content writers have their work published automatically, a sort of simple automated publishing solution.

We find this utility very helpful and hope it is the same for you.
Please take into account we have tested the scripts only on a Windows environment using Forrest 0.6
We consider this utility as a starting point for an inspiration as improvements can be done and as well a better integration with Forrest.

Credits:
The inspiration came from this posting:
http://issues.apache.org/eyebrowse/ReadMsg?listId=248&msgNo=502

We have also noticed (after we wrote the utility!) some similarities to the libre project:
http://forrest.apache.org/docs/libre-intro.html

Looking forward to hear your feedback.

Fabio del Percio (fdelpercio@fonzi.com) and Bruno Fonzi (forrest@fonzi.com)

The package includes:

- Build.xml
Creates the site.xml and tabs.xml of a forrest site.
The build file can be located in any directory as it reads properties from site.properties. 
It calls createtabs.xml and createsite.xml.

- site.properties
site.properties is the property file for our build.

- createtabs.xml
Creates tabs.xml. It creates an "Home" tab and a new tab for each directory
present in the root directory.
The root ("Home") directory and each of this directories must contain an index.xml
file.

- createsite.xml
Creates the site.xml. It creates an xml <tag> for each directory present in the
root directory.
For each of this directories it calls the ant file setSubTags.xml and setSubTagsRecursive.xml.

- setSubTags.xml and setSubTagsRecursive.xml
They generate links for each file found in the directory, creates a subdir tag
for each folder found in the directory and repeat recursively the same task for
these directories.
setSubTags.xml and setSubTagsRecursive.xml are actually the exact copy of each other.
It was necessary to duplicate the two scripts as ANT does not support recursive calls.
If anyone has a better solution I would be happy to hear from you.


Requirements:
Ant v. 1.6.x
And ant-contrib-1.0b1.jar 
http://sourceforge.net/projects/ant-contrib


---------------------------------------------------------------------
JIRA INFORMATION:
This message is automatically generated by JIRA.

If you think it was sent incorrectly contact one of the administrators:
   http://issues.cocoondev.org//secure/Administrators.jspa

If you want more information on JIRA, or have a bug to report see:
   http://www.atlassian.com/software/jira