1、打包跳过测试代码

<plugin>
   <groupId>org.apache.maven.plugins</groupId>
   <artifactId>maven-surefire-plugin</artifactId>
   <version>2.18.1</version>
   <configuration>
     <skipTests>true</skipTests>
   </configuration>
</plugin>

2、打包项目源码

<plugin>
<artifactId>maven-source-plugin</artifactId>
<version>2.1</version>
<configuration>
<attach>true</attach>
</configuration>
<executions>
<execution>
<phase>package</phase>
<goals>
<goal>jar</goal>
</goals>
</execution>
</executions>
</plugin>

package范围打包

3、整合jetty插件

<plugin>
<groupId>org.eclipse.jetty</groupId>
<artifactId>jetty-maven-plugin</artifactId>
<version>9.2.8.v20150217</version>
<configuration>
<scanIntervalSeconds>10</scanIntervalSeconds>
<httpConnector>
<port>8888</port>
</httpConnector>
<webApp>
<contextPath>/sms</contextPath>
</webApp>
<war>${project.build.directory}/luna.war</war>
</configuration>
</plugin>

port:启动端口,contextPath:启动应用名称,scanIntervalSeconds:每隔10s钟扫描一次,war:打包项目

4、整合tomcat7插件

<plugin>
<groupId>org.apache.tomcat.maven</groupId>
<artifactId>tomcat7-maven-plugin</artifactId>
<version>2.2</version>
<configuration>
<port>8888</port>
<path>/luna</path>
<uriEncoding>UTF-8</uriEncoding>
<server>tomcat7</server>
</configuration>
</plugin>

最新文章

  1. [示例] Firemonkey 不规则按钮实做
  2. jpa 表字段转bean对象
  3. fatal error LNK1112: module machine type &#39;x64&#39; conflicts with target machine type &#39;X86&#39;
  4. uva 129
  5. REST 测试工具
  6. c++动态库与静态库
  7. IT行业能力细分
  8. SELECT中的if_case流程函数
  9. 网页端HTML使用MQTTJs订阅RabbitMQ数据
  10. Android源代码下载 “Gerrit下载源代码”
  11. docker学习-lnmp+redis之搭建redis容器服务
  12. Java的优先级任务队列的实践
  13. day14(1)--递归、匿名函数、内置函数
  14. 图片居中table-cell
  15. 第一个Python小爬虫
  16. MySQL 基础十 性能优化
  17. Architecture options to run a workflow engine
  18. Mongodb主从复制 及 副本集+分片集群梳理
  19. float right
  20. 向Nexus仓库推送/使用各种组件

热门文章

  1. 160. Intersection of Two Linked Lists
  2. bzoj 1012 维护一个单调数列
  3. html5中新的标准属性
  4. AttributeError: &#39;NoneType&#39; object has no attribute &#39;bytes&#39; python3.4 win64
  5. AXIOM解析XML 详细原理
  6. HDU-5536 Chip Factory (字典树)
  7. MySQL中日期与字符串相互转换,并进行日期比较查询
  8. Ubuntu 安装和配置redis数据库
  9. 二十四种设计模式:提供者模式(Provider Pattern)
  10. JSP 相关试题(二)