maven pom功能说明

来源:互联网 发布:mac怎么分区 编辑:程序博客网 时间:2024/05/18 23:57

pom文件中配置环境参数,根据不同环境自动打包

这篇文章介绍的非常简单明了:http://www.mzone.cc/article/282.html


打包不同jdk版本的包

http://www.mzone.cc/article/626.html


配置install时不执行单元测试

<plugin>  <groupId>org.apache.maven.plugins</groupId>  <artifactId>maven-surefire-plugin</artifactId>  <configuration>    <skip>true</skip>  </configuration></plugin>

配置install时自动打包源码
<plugin>  <artifactId>maven-source-plugin</artifactId>  <version>2.1</version>  <configuration>    <attach>true</attach>  </configuration>  <executions>    <execution>      <phase>compile</phase>      <goals>        <goal>jar</goal>      </goals>    </execution>  </executions></plugin>

如何让maven依赖本地jar

<dependency><groupId>org.apache</groupId><artifactId>test</artifactId><version>1.0</version><scope>system</scope><systemPath>${basedir}/src/main/webapp/WEB-INF/lib/paypal_base.jar</systemPath></dependency>


原创粉丝点击