vsitegen - User Guide

For generating a site with vsitegen a user needs to write 3 objects: a navigation configuration file, a velocity template and a page content file (one per page).
As example you can see the files used for generating this page.

Navigation configuration file

This is the navigation configuration file used for generating this site:

<?xml version="1.0" encoding="utf-8"?>
<navigation>
    <section id="documentation" label="Documentation">
        <page id="overview" label="Overview" file="index" />
        <page id="dependencies" label="Dependencies" file="dependencies" />
        <page id="userguide" label="User Guide" file="userguide" />
    </section>
    <section id="reports" label="Project reports">
        <link id="javadoc" label="JavaDocs" url="javadoc/index.html" newwindow="true" />
        <link id="checkstyle" label="CheckStyle report" url="checkstyle_report.html" newwindow="true" />
        <link id="cpd" label="CPD report" url="cpd.html" newwindow="true" />
        <link id="javancss" label="JavaNCSS report" url="javancss.html" newwindow="true" />
        <link id="jdepend" label="JDepend report" url="jdepend.html" newwindow="true" />
    </section>
</navigation>

Velocity template

This is the velocity template used for building this page. It has references to the following variables:

  • projectName: current project name, as defined in the ant task;
  • navigation: object describing the current navigation tree;
  • pageId: current page id;
  • content: current page main content;
  • generationTime: current page generation date and time.

Page content file

This is the content file used for generating this page.