zoukankan      html  css  js  c++  java
  • Maven 的聚合

    1.maven的集合

    1.假设我们已经拥有了项目Age,项目Bge,项目Cge,项目Summary

    2.我们在项目Summary的pom.xml中引入集合标签(以项目Summary汇总)

    <modules>

        <module>../引入的项artifactId</module>

        <module>../引入的项artifactId</module>

    </modules>

    例子:

    Summary的pom.xml如下

    <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>com.imooc.Summary</groupId>
      <artifactId>Summary</artifactId>
      <version>0.0.1-SNAPSHOT</version>
      <packaging>pom</packaging>
    
      <name>Summary</name>
      <url>http://maven.apache.org</url>
    
      <properties>
        <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
      </properties>
      
      <modules>
              <module>../Age</module>
              <module>../Bge</module>
              <module>../Cge</module>
      </modules>
    </project>

    作用:项目Summary执行install  ,clean  ,compile,test时,存在module中的项目会一起执行这一个命令

    周永发
  • 相关阅读:
    笨蛋蛋都能学会的开机grub消除(双系统开机总是黑屏肿么办--多半是欠reset)
    Find a way HDU
    非常可乐 HDU
    Oil Deposits HDU
    迷宫问题 POJ
    Fire!
    Fire Game FZU
    Pots POJ
    Prime Path POJ
    Jquery鼠标悬停按钮图标动态变化效果
  • 原文地址:https://www.cnblogs.com/yvanBk/p/9076485.html
Copyright © 2011-2022 走看看