pom.xml parsing in Maven

   <!-- specifies the current pom version -->
   <modelVersion>4.0.0</modelVersion>
  <groupId>reverse company URL + project name</groupId>
  <artifactId>project name+module</artifactId>
  <!-- The first 0 is the major version number
  The second 0 is the branch version number
  The third 0 is the minor version number
  0.0.1
  snapshot: snapshot
  alpha: Internal public beta
  beta: public beta
  Release: stable
  GA: Formal
  -->
  <version>0.0.1-SNAPSHOT</version>
  <!--The default is jar
  war zip pom
  -->
  <packaging>jar</packaging>
   <!--Item description name-->
  <name>hi</name>
  <!--Project address-->
  <!--Item Description-->
  <description></description>
   <!--Developer list-->
  <develops></develops>
   <!--License Information-->
  <licenses></licenses>
  <!--Organization information-->
  <organization></organization>
  <properties>
    <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
  </properties>
   <!--Dependency list-->
  <dependencies>
     <!--dependencies-->
    <dependency>
      <groupId>junit</groupId>
      <artifactId>junit</artifactId>
      <version>3.8.1</version>
       <!--Dependency scope-->
      <scope>test</scope>
       <!--Setting dependencies is optional-->
      <optional></optional>
       <!--Exclude dependencies transitive list-->
      <exclusions>
        <exclusion>
        </exclusion>
      </exclusions>
    </dependency>
  </dependencies>
  <!--依赖的管理-->
  <dependencyManagement>
   <dependencies>
    <dependency></dependency>
   </dependencies>
  </dependencyManagement>
  <!--用于定义构建信息-->
  <build>
    <!--插件的列表-->
      <plugins>
          <plugin>
                <groupId>org.apache.maven.plugins</groupId>
              <artifactId>maven-source-plugin</artifactId>
              <version>2.4</version>
              <executions>
                  <execution>
                      <phase>package</phase>
                      <goals>
                          <goal>jar-no-fork</goal>
                      </goals>
                  </execution>
              </executions>
          </plugin>
      </plugins>
  </build>
  <parent></parent>
  <modules>
    <module></module>
  </modules>

 

</project>

Guess you like

Origin http://10.200.1.11:23101/article/api/json?id=326834795&siteId=291194637