You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@maven.apache.org by mike witters <mi...@yahoo.com> on 2003/02/04 21:26:41 UTC

Usage Question

Hopefully this question isnt too low level.  I've not used Maven before
beyond installation and simple site generation.  I checked the FAQ and the
site documentation and couldn't see an answer to this question.

I have looked into the documentation on the Maven site and haven't seen any
docs related to the amount of 'website documentation' that is shown under
the projects that use Maven (the 'Powered By' page).  I used Maven to
generate a website based on a project we have and it only generated a small
subset of all the links/menu items shown on the pages linked to on the
'powered by' page.

How do I get Maven to add links like that?  For instance, if I provide a
'User Guide' page for our project, how does that get added to the
Maven-generated documentation as a link on the nav menu?  I realize I could
add it to the html files generated and left in the 'target' directory, but
that seems counter-productive...since it would disappear after each
site:generate.

Again, sorry if this has been addressed somewhere already, but I didn't see
it.

Thanks for any information.
Mike


Re: Usage Question

Posted by Pete Kazmier <pe...@kazmier.com>.
>>>>> mike witters writes:

mike> For instance, if I provide a 'User Guide' page for our project,
mike> how does that get added to the Maven-generated documentation as
mike> a link on the nav menu?

The contents of the navbar is controlled by the 'navigation.xml' file
located in your 'xdocs' directory.  The format of this file is like
the following (here is the one used by Maven):

<?xml version="1.0" encoding="ISO-8859-1"?>
<project name="Maven">
  <title>Maven</title>
  <body>
    <menu name="Overview">
      <item name="Goals"                   href="/goals.html"/>
      <item name="Features"                href="/features.html"/>
      <item name="Download"                href="/start/download.html"/>
      <item name="News and Status"         href="/status.html"/>
      <item name="Getting Started"         href="/start/index.html"/>
      <item name="Reference"               href="/reference/index.html"/>
      <item name="FAQ"                     href="/faq.html"/>
      <item name="Powered By"              href="/powered.html"/>
    </menu>
  </body>
</project>

Basically, you just add <item/> to add a new link to a section of the
navbar.  If you want to create a new section, add a new <menu/>, and
then add an <item/> in there.  You can also nest <menu/> tags to
create "expanding" hierarchies.  

As for the location of your user's guide, write an xdoc and place it
in the 'xdocs' directory.  The xdoc format is pretty simple, just look
at one of the many docs in the maven xdocs directory for an example.
If you don't want to use xdoc, you can use the APT (almost plain text)
plugin which lets you write your documentation using 'wiki'-like
notation.