forrest-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Bruno Fonzi" <>
Subject Filesystem Automated Publishing Utility
Date Thu, 21 Oct 2004 15:31:42 GMT


>From [JIRA] Created: (FOR-328)

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 <>
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.

The inspiration came from this posting:

We have also noticed (after we wrote the utility!) some similarities to the libre project:

Looking forward to hear your feedback.

Fabio del Percio ( and Bruno Fonzi (

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

It calls createtabs.xml and createsite.xml.

- 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

- 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.

Ant v. 1.6.x
And ant-contrib-1.0b1.jar

=== Start-of Internet E-mail Confidentiality Footer ===

L'uso non autorizzato di questo messaggio o dei suoi allegati e' vietato e potrebbe costituire
Se ha ricevuto per errore questo messaggio, La preghiamo di informarci e di distruggerlo immediatamente
coi suoi allegati.
Le dichiarazioni contenute in questo messaggio o nei suoi allegati non impegnano SECETI S.p.A.
nei confronti del destinatario o di terzi.
SECETI S.p.A. non si assume alcuna responsabilita' per eventuali intercettazioni, modifiche
o danneggiamenti del presente messaggio.

Any unauthorized use of this e-mail or any of its attachments is prohibited and could constitute
an offence.
If you are not the intended addressee please advise immediately the sender and destroy the
message and its attachments.
The contents of this message shall be understood as neither given nor endorsed by SECETI S.p.A.
SECETI S.p.A. does not accept liability for corruption, interception or amendment, if any,
or the consequences thereof.

View raw message