Maven: Skinning Generated Site


The default Maven generated site looks like web pages created in the 80s:-


The good news is Maven allows us to change the skin.

To use one of these pre-defined skins, create site.xml at this location:-

├── pom.xml
├── src
│   ├── main
│   │   └── java
│   │       └── ...
│   ├── site
│   │   └── site.xml

In site.xml, enter the following:-

<project xmlns:xsi=""

    <publishDate position="right" format="MMMM dd, yyyy"/>
        <logo img="#" alt=""/>


        <menu ref="reports"/>

In the above example, we use Maven Fluido Skin.

In Maven 3, site:attach-descriptor has been removed from the built-in lifecycle bindings, so we need to explicitly define attach-descriptor goal in Maven Site Plugin to pick up src/site/site.xml.


When you run mvn clean site, oh hey, welcome to 21st century!

Posted in Uncategorized Tagged

Leave a Reply

Your email address will not be published.