Site
****
Links
=====
- Hudson - Maven Site, :doc:`hudson/maven-site`
- `Maven 2 Site Plugin`_
- `Maven 2 Archetype Plugin - Creating a site`_
- `Maven 2: Getting ``mvn site:deploy`` to work`_
- http://maven.apache.org/plugins/maven-pdf-plugin/
Generate a PDF version of your project's documentation.
Create
======
To create a simple site: (``site.xml``, ``apt`` folder and ``index.apt``):
::
mvn archetype:create -DgroupId=com.sample -DartifactId=sample-app -DarchetypeArtifactId=maven-archetype-site-simple
A more complete version of a site (``fml``, ``fr``, ``xdoc``), can be created
using ``maven-archetype-site``:
::
mvn archetype:create -DgroupId=com.sample -DartifactId=sample-app -DarchetypeArtifactId=maven-archetype-site
Insert
------
To insert a site within an existing project, the following *appears* to work:
::
mvn archetype:create -DarchetypeArtifactId=maven-archetype-site-simple
You may like to add the project name and a skin to the generated ``site.xml``:
::
org.apache.maven.skins
maven-classic-skin
1.0
FAQ
===
To add links to FAQ items, use the anchor tag e.g.
::
Where can I find the national news?
Have a look at the
BBC News Web Site
Issue Management and Continuous Integration
===========================================
Add the following to your ``pom.xml`` file:
::
hudson
http://server.name:8080/
Redmine
http://my.redmine.com/projects/show/myapp
Multi Module
============
Notes on creating multi-module sites, :doc:`mvn-plugin-site-multi-module`.
Reports
=======
- NCSS - Report Plugin, :doc:`mvn-plugin-ncss`.
- PMD - Report Plugin, :doc:`mvn-plugin-pmd`.
There are many plugins which generate reports for the site. Here are the ones
I use:
::
../../misc/howto/maven/pom-standard-reports.xml
**Note**: I have updated some report definitions in the multi-module sample,
Review the changes in:
::
../../misc/howto/maven/pom-standard-reports-multi-module.xml
Don't forget to add the ``maven-site-plugin`` to ``pom.xml``:
::
org.codehaus.mojo
cobertura-maven-plugin
clean
org.apache.maven.plugins
maven-site-plugin
en
...and a ``reports`` element to the ``site.xml`` file:
::