Skip to content

Commit

Permalink
re
Browse files Browse the repository at this point in the history
  • Loading branch information
knightliao committed Oct 11, 2016
1 parent 73cafb2 commit 54c69f2
Showing 1 changed file with 113 additions and 217 deletions.
330 changes: 113 additions & 217 deletions pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -545,259 +545,155 @@

<finalName>disconf-base</finalName>

<pluginManagement>
<!-- 覆盖率 mvn test -->
<plugins>
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>cobertura-maven-plugin</artifactId>
<version>2.6</version>
<configuration>
<formats>
<format>xml</format>
</formats>
<aggregate>true</aggregate>
<instrumentation>
<excludes>
<exclude>**/*Proto.class</exclude>
<exclude>**/*Proto$*.class</exclude>
<exclude>**/*Test.class</exclude>
<exclude>**/*Controller.class</exclude>
<exclude>**/*Vo.class</exclude>
<exclude>**/*Form.class</exclude>
<exclude>**/baidu/ub/**/*.class</exclude>
</excludes>
</instrumentation>
</configuration>
<executions>
<execution>
<phase>package</phase>
<goals>
<goal>cobertura</goal>
</goals>
</execution>
</executions>
</plugin>

<!-- 编译 -->
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-compiler-plugin</artifactId>
<version>2.3.1</version>
<configuration>
<source>${source.version}</source>
<target>${target.version}</target>
<encoding>${encoding}</encoding>
<failOnError>true</failOnError>
<showDeprecation>true</showDeprecation>
<showWarnings>true</showWarnings>
<compilerArguments>
<verbose/>
<bootclasspath>${java.home}/lib/rt.jar</bootclasspath>
</compilerArguments>
</configuration>

<dependencies>
<dependency>
<groupId>org.codehaus.plexus</groupId>
<artifactId>plexus-compiler-javac</artifactId>
<version>1.8.1</version>
</dependency>
</dependencies>
</plugin>

<!-- JAR包 -->
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-jar-plugin</artifactId>
<version>2.4</version>
</plugin>

<!-- war包 -->
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-war-plugin</artifactId>
<version>2.1.1</version>
<configuration>
<webXml>${project.basedir}/src/main/webapp/WEB-INF/web.xml</webXml>
</configuration>
</plugin>

<!-- embedded web servers -->
<plugin>
<groupId>org.mortbay.jetty</groupId>
<artifactId>maven-jetty-plugin</artifactId>
<version>6.1.10</version>
</plugin>

<plugin>
<groupId>org.apache.tomcat.maven</groupId>
<artifactId>tomcat6-maven-plugin</artifactId>
<version>2.0</version>
</plugin>

<!-- auto deploy plugin -->
<plugin>
<groupId>org.codehaus.cargo</groupId>
<artifactId>cargo-maven2-plugin</artifactId>
<version>1.2.0</version>
</plugin>

<!-- 单测 -->
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-surefire-plugin</artifactId>
<version>2.5</version>
<configuration>
<argLine>-Dfile.encoding=UTF-8</argLine>
<includes>
<include>**/*TestCase.java</include>
</includes>
<!-- 覆盖率 mvn test -->
<plugins>
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>cobertura-maven-plugin</artifactId>
<version>2.6</version>
<configuration>
<formats>
<format>xml</format>
<format>html</format>
</formats>
<aggregate>true</aggregate>
<instrumentation>
<excludes>
<exclude>**/*ServiceTest.java</exclude>
<exclude>**/TempDaoTest.java</exclude>
<exclude>**/*Proto.class</exclude>
<exclude>**/*Proto$*.class</exclude>
<exclude>**/*Test.class</exclude>
<exclude>**/*Controller.class</exclude>
<exclude>**/*Vo.class</exclude>
<exclude>**/*Form.class</exclude>
</excludes>
</configuration>
</plugin>

<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-source-plugin</artifactId>
<executions>
<execution>
<id>attach-sources</id>
<goals>
<goal>jar</goal>
</goals>
</execution>
</executions>
</plugin>

<!-- 为了github的测试覆盖率 -->
<plugin>
<groupId>org.eluder.coveralls</groupId>
<artifactId>coveralls-maven-plugin</artifactId>
<version>3.1.0</version>
</plugin>

<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-javadoc-plugin</artifactId>
<executions>
<execution>
<id>attach-javadocs</id>
<goals>
<goal>jar</goal>
</goals>
</execution>
</executions>
</plugin>

</plugins>
</pluginManagement>
</build>
</instrumentation>
</configuration>
<executions>
<execution>
<phase>package</phase>
<goals>
<goal>cobertura</goal>
</goals>
</execution>
</executions>
</plugin>

<!-- TEST 報告 mvn site -->
<reporting>
<plugins>
<!-- 编译 -->
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-compiler-plugin</artifactId>
<version>2.3.1</version>
<configuration>
<source>${source.version}</source>
<target>${target.version}</target>
<encoding>${encoding}</encoding>
<failOnError>true</failOnError>
<showDeprecation>true</showDeprecation>
<showWarnings>true</showWarnings>
<compilerArguments>
<verbose/>
<bootclasspath>${java.home}/lib/rt.jar</bootclasspath>
</compilerArguments>
</configuration>

<dependencies>
<dependency>
<groupId>org.codehaus.plexus</groupId>
<artifactId>plexus-compiler-javac</artifactId>
<version>1.8.1</version>
</dependency>
</dependencies>
</plugin>

<!-- checkstyle -->
<!-- JAR包 -->
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-checkstyle-plugin</artifactId>
<version>2.9.1</version>
<artifactId>maven-jar-plugin</artifactId>
<version>2.4</version>
</plugin>

<!-- pmd -->
<!-- war包 -->
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-pmd-plugin</artifactId>
<version>3.0.1</version>
<artifactId>maven-war-plugin</artifactId>
<version>2.1.1</version>
<configuration>
<aggregate>true</aggregate>
<targetJdk>1.6</targetJdk>
<webXml>${project.basedir}/src/main/webapp/WEB-INF/web.xml</webXml>
</configuration>
</plugin>

<!-- 定义Site生成的Index -->
<!-- embedded web servers -->
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-project-info-reports-plugin</artifactId>
<version>2.7</version>
<reportSets>
<reportSet>
<reports>
<report>index</report>
<report>summary</report>
</reports>
</reportSet>
</reportSets>
<groupId>org.mortbay.jetty</groupId>
<artifactId>maven-jetty-plugin</artifactId>
<version>6.1.10</version>
</plugin>

<!-- site UT 插件 -->
<plugin>
<groupId>org.apache.tomcat.maven</groupId>
<artifactId>tomcat6-maven-plugin</artifactId>
<version>2.0</version>
</plugin>

<!-- auto deploy plugin -->
<plugin>
<groupId>org.codehaus.cargo</groupId>
<artifactId>cargo-maven2-plugin</artifactId>
<version>1.2.0</version>
</plugin>

<!-- 单测 -->
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-surefire-report-plugin</artifactId>
<artifactId>maven-surefire-plugin</artifactId>
<version>2.5</version>
<configuration>
<aggregate>true</aggregate>
<argLine>-Dfile.encoding=UTF-8</argLine>
<includes>
<include>**/*TestCase.java</include>
</includes>
<excludes>
<exclude>**/*ServiceTest.java</exclude>
<exclude>**/TempDaoTest.java</exclude>
</excludes>
</configuration>
<reportSets>
<reportSet>
<reports>
<!-- 单测RUN一次,其它地方都可以用 -->
<report>report-only</report>
</reports>
</reportSet>
</reportSets>
</plugin>

<!-- 覆盖率 -->
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>cobertura-maven-plugin</artifactId>
<version>2.6</version>
<configuration>
<encoding>UTF-8</encoding>
<aggregate>true</aggregate>
<formats>
<format>xml</format>
<format>html</format>
</formats>
<instrumentation>
<excludes>
<exclude>**/*Proto.class</exclude>
<exclude>**/*Proto$*.class</exclude>
<exclude>**/*Test.class</exclude>
<exclude>**/*Controller.class</exclude>
<exclude>**/*Vo.class</exclude>
<exclude>**/*Form.class</exclude>
</excludes>
</instrumentation>
<check/>
</configuration>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-source-plugin</artifactId>
<executions>
<execution>
<id>attach-sources</id>
<goals>
<goal>jar</goal>
</goals>
</execution>
</executions>
</plugin>

<!-- findbugs -->
<!-- 为了github的测试覆盖率 -->
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>findbugs-maven-plugin</artifactId>
<version>2.5.2</version>
<configuration>
<aggregate>true</aggregate>

</configuration>
<groupId>org.eluder.coveralls</groupId>
<artifactId>coveralls-maven-plugin</artifactId>
<version>3.1.0</version>
</plugin>

<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-release-plugin</artifactId>
<version>2.5</version>
<artifactId>maven-javadoc-plugin</artifactId>
<executions>
<execution>
<id>attach-javadocs</id>
<goals>
<goal>jar</goal>
</goals>
</execution>
</executions>
</plugin>

</plugins>
</reporting>
</build>

<developers>
<developer>
Expand Down

0 comments on commit 54c69f2

Please sign in to comment.