Maven根项目
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>
<groupId>org.youi</groupId>
<artifactId>youi-it</artifactId>
<version>1.0-SNAPSHOT</version>
<inceptionYear>2012-04-16</inceptionYear>
<packaging>pom</packaging>
<name>youi-it</name>
<url>http://www.youi.org</url>
<properties>
<company>youi</company>
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
<sonar.jdbc.url>jdbc:mysql://bdp.youisoft.com.cn:85/sonar?useUnicode=true&characterEncoding=utf8&rewriteBatchedStatements=true</sonar.jdbc.url>
<sonar.host.url>http://bdp.youisoft.com.cn/sonar</sonar.host.url>
<sonar.forceAnalysis>true</sonar.forceAnalysis>
<licenseName>youi-Janly</licenseName>
</properties>
<distributionManagement>
<repository>
<url>http://bdp.youisoft.com.cn/nexus/content/repositories/releases</url>
<id>youisoft-releases</id></repository>
<snapshotRepository>
<url>http://bdp.youisoft.com.cn/nexus/content/repositories/snapshots</url>
<id>youisoft-snapshots</id></snapshotRepository></distributionManagement>
<organization>
<name>youi</name>
<url>http://www.youi.org</url>
</organization>
<licenses>
<license>
<name>The youi Software License, Version 1.0</name>
<url>http://www.youi.org/licenses/LICENSE-1.0.txt</url>
<distribution>repo</distribution>
</license>
</licenses>
<developers>
<developer>
<email>[email protected]</email>
</developer>
</developers>
<build>
<finalName>${project.name}-${project.version}</finalName>
<pluginManagement>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-dependency-plugin</artifactId>
<version>2.1</version>
<!--
<executions>
<execution>
<id>copy-dependencies</id>
<phase>prepare-package</phase>
<goals>
<goal>copy-dependencies</goal>
</goals>
<configuration>
<outputDirectory>${project.build.directory}/lib</outputDirectory>
</configuration>
</execution>
</executions>
-->
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-jar-plugin</artifactId>
<version>2.1</version>
<configuration>
<archive>
<manifest>
<addClasspath>true</addClasspath>
<classpathPrefix>lib/</classpathPrefix>
<mainClass>${main.class}</mainClass>
</manifest>
</archive>
</configuration>
<executions>
<execution>
<id>package</id>
<phase>package</phase>
<goals>
<goal>jar</goal>
</goals>
</execution>
</executions>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-assembly-plugin</artifactId>
<version>2.1</version>
<configuration>
<descriptorRefs>
<descriptorRef>jar-with-dependencies</descriptorRef>
</descriptorRefs>
<archive>
<manifest>
<mainClass>${main.class}</mainClass>
</manifest>
</archive>
</configuration>
</plugin>
<plugin>
<groupId>org.apache.felix</groupId>
<artifactId>maven-bundle-plugin</artifactId>
<extensions>true</extensions>
<version>1.4.0</version>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-antrun-plugin</artifactId>
<version>1.6</version>
</plugin>
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>castor-maven-plugin</artifactId>
<version>2.1</version>
</plugin>
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>exec-maven-plugin</artifactId>
<version>1.2.1</version>
</plugin>
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>buildnumber-maven-plugin</artifactId>
<version>1.1</version>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-scm-plugin</artifactId>
<version>1.7</version>
</plugin>
<!-- code quality -->
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>sonar-maven-plugin</artifactId>
<version>2.0</version>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-checkstyle-plugin</artifactId>
<version>2.9.1</version>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-pmd-plugin</artifactId>
<version>2.7.1</version>
</plugin>
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>findbugs-maven-plugin</artifactId>
<version>2.3.2</version>
</plugin>
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>cobertura-maven-plugin</artifactId>
<version>2.5.1</version>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-jxr-plugin</artifactId>
<version>2.3</version>
</plugin>
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>clirr-maven-plugin</artifactId>
<version>2.3</version>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-source-plugin</artifactId>
<version>2.1.2</version>
<configuration>
<attach>true</attach>
</configuration>
<executions>
<execution>
<id>process-sources</id>
<phase>process-sources</phase>
<goals>
<goal>jar</goal>
</goals>
</execution>
<execution>
<id>process-test-sources</id>
<phase>process-test-sources</phase>
<goals>
<goal>test-jar</goal>
</goals>
</execution>
</executions>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-compiler-plugin</artifactId>
<version>2.0.2</version>
<configuration>
<source>1.6</source>
<target>1.6</target>
<encoding>UTF-8</encoding>
</configuration>
</plugin>
<plugin>
<artifactId>tomcat-maven-plugin</artifactId>
<groupId>org.codehaus.mojo</groupId>
<configuration>
<port>8000</port>
</configuration>
<version>1.1</version>
</plugin>
<plugin>
<groupId>org.apache.avro</groupId>
<artifactId>avro-maven-plugin</artifactId>
<version>1.7.6</version>
<executions>
<execution>
<id>avro-generate-sources</id>
<phase>generate-sources</phase>
<goals>
<goal>schema</goal>
</goals>
<configuration>
<sourceDirectory>${project.basedir}/src/main/avro/</sourceDirectory>
<outputDirectory>${project.basedir}/src/main/java/</outputDirectory>
</configuration>
</execution>
</executions>
</plugin>
</plugins>
</pluginManagement>
<plugins>
</plugins>
<filters>
<filter>${user.home}/mx.properties</filter></filters>
<resources>
<resource>
<directory>src\main\resources</directory>
<filtering>true</filtering></resource></resources>
<testResources>
<testResource>
<directory>src\test\resources</directory>
<filtering>true</filtering></testResource></testResources>
</build>
</project>