Author: echatellier Date: 2009-09-04 15:14:08 +0200 (Fri, 04 Sep 2009) New Revision: 2768 Modified: trunk/pollen-ui/pom.xml trunk/pom.xml Log: Add launcher code on war based on winstone Modified: trunk/pollen-ui/pom.xml =================================================================== --- trunk/pollen-ui/pom.xml 2009-09-01 12:12:19 UTC (rev 2767) +++ trunk/pollen-ui/pom.xml 2009-09-04 13:14:08 UTC (rev 2768) @@ -63,6 +63,11 @@ <groupId>junit</groupId> <artifactId>junit</artifactId> </dependency> + <dependency> + <groupId>net.sourceforge.winstone</groupId> + <artifactId>winstone</artifactId> + <scope>provided</scope> + </dependency> </dependencies> <!-- ************************************************************* --> @@ -80,33 +85,51 @@ <packaging>war</packaging> <reporting> - <!-- - Adds a report detailing the components, mixins and base - classes defined by this module. - --> - <!-- - <plugins> <plugin> <groupId>org.apache.tapestry</groupId> - <artifactId>tapestry-component-report</artifactId> - <version>${tapestry.version}</version> <configuration> - <rootPackage>org.chorem.pollen.ui</rootPackage> - </configuration> </plugin> </plugins> - --> + <!-- Adds a report detailing the components, mixins and base classes defined by this module. --> + <!-- <plugins> + <plugin> + <groupId>org.apache.tapestry</groupId> + <artifactId>tapestry-component-report</artifactId> + <version>${tapestry.version}</version> + <configuration> + <rootPackage>org.chorem.pollen.ui</rootPackage> + </configuration> + </plugin> + </plugins> --> </reporting> <build> + <!-- call result war : pollen-xxx.war --> <finalName>pollen-${project.version}</finalName> + + <!-- Add main class into war to make it executable --> <plugins> <plugin> - <groupId>net.sf.alchim</groupId> - <artifactId>winstone-maven-plugin</artifactId> - <executions> - <execution> - <goals> - <goal>embed</goal> - </goals> - <phase>package</phase> - </execution> - </executions> + <artifactId>maven-war-plugin</artifactId> + <version>2.1-beta-1</version> + <configuration> + <webResources> + <resource> + <directory>${basedir}/target/classes</directory> + <includes> + <include>**/war/*</include> + </includes> + </resource> + </webResources> + <!-- for putting Main-Class into war --> + <archive> + <manifest> + <mainClass>org.chorem.pollen.war.PollenWarLauncher</mainClass> + </manifest> + </archive> + <overlays> + <overlay> + <groupId>net.sourceforge.winstone</groupId> + <artifactId>winstone</artifactId> + <type>jar</type> + </overlay> + </overlays> + </configuration> </plugin> </plugins> </build> Modified: trunk/pom.xml =================================================================== --- trunk/pom.xml 2009-09-01 12:12:19 UTC (rev 2767) +++ trunk/pom.xml 2009-09-04 13:14:08 UTC (rev 2768) @@ -131,7 +131,11 @@ <version>4.6</version> <scope>test</scope> </dependency> - + <dependency> + <groupId>net.sourceforge.winstone</groupId> + <artifactId>winstone</artifactId> + <version>0.9.10</version> + </dependency> </dependencies> </dependencyManagement>