<?xml version="1.0" encoding="UTF-8"?>
<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>club.ximeng.util</groupId>
  <artifactId>IdentityCard</artifactId>
  <name>${project.artifactId}</name>
  <description>身份证工具</description>

  <properties>
    <!--项目编译JDK版本-->
    <maven.compiler.source>8</maven.compiler.source>
    <maven.compiler.target>8</maven.compiler.target>
    <!--项目编码-->
    <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
    <!--    &lt;!&ndash;插件版本&ndash;&gt;-->
    <!--    <maven-compiler-plugin.version>3.8.1</maven-compiler-plugin.version>-->
    <!--    <maven-release-plugin.version>3.0.0-M1</maven-release-plugin.version>-->
    <!--    <maven-source-plugin.version>3.2.1</maven-source-plugin.version>-->
    <!--    <maven-javadoc-plugin.version>3.2.0</maven-javadoc-plugin.version>-->
    <!--    <nexus-staging-maven-plugin.version>1.6.8</nexus-staging-maven-plugin.version>-->
    <!--    <maven-gpg-plugin.version>1.6</maven-gpg-plugin.version>-->
    <!--    <maven-deploy-plugin.version>3.0.0-M1</maven-deploy-plugin.version>-->
  </properties>

  <dependencies>
    <dependency>
      <groupId>junit</groupId>
      <artifactId>junit</artifactId>
      <version>4.12</version>
      <scope>test</scope>
    </dependency>
  </dependencies>
  <version>1.0</version>
  <!-- 项目 URL -->
  <url>https://github.com/Ximeng0918/IdentityCard</url>
  <!-- SCM信息 -->
  <scm>
    <url>https://github.com/Ximeng0918/IdentityCard</url>
    <connection>scm:git:https://github.com/Ximeng0918/IdentityCard.git</connection>
    <developerConnection>scm:git:https://github.com/Ximeng0918/IdentityCard.git</developerConnection>
    <tag>HEAD</tag>
  </scm>
  <!-- 开发者信息 -->
  <developers>
    <developer>
      <id>ximeng</id>
      <name>ximeng</name>
      <email>960132232@qq.com</email>
      <url>https://www.ximeng.club</url>
      <timezone>+8</timezone>
    </developer>
  </developers>

  <licenses>
    <license>
      <name>The Apache Software License, Version 2.0</name>
      <url>http://www.apache.org/licenses/LICENSE-2.0.txt</url>
    </license>
  </licenses>

  <repositories>
    <repository>
      <id>ALiYun</id>
      <name>ALiYun</name>
      <url>https://maven.aliyun.com/repository/public</url>
    </repository>
  </repositories>

  <build>
    <finalName>${project.artifactId}-${project.version}</finalName>
    <resources>
      <resource>
        <directory>src/main/resources</directory>
        <filtering>true</filtering>
      </resource>
    </resources>
  </build>

  <profiles>
    <!--release-->
    <profile>
      <id>release</id>
      <build>
        <plugins>
          <plugin>
            <groupId>org.apache.maven.plugins</groupId>
            <artifactId>maven-deploy-plugin</artifactId>
            <version>3.0.0-M1</version>
          </plugin>
          <!-- Source -->
          <plugin>
            <groupId>org.apache.maven.plugins</groupId>
            <artifactId>maven-source-plugin</artifactId>
            <version>3.2.1</version>
            <executions>
              <execution>
                <id>attach-sources</id>
                <phase>package</phase>
                <goals>
                  <goal>jar-no-fork</goal>
                </goals>
              </execution>
            </executions>
          </plugin>
          <!-- Javadoc -->
          <plugin>
            <groupId>org.apache.maven.plugins</groupId>
            <artifactId>maven-javadoc-plugin</artifactId>
            <version>3.2.0</version>
            <configuration>
              <show>package</show>
              <tags>
                <tag>
                  <name>date</name>
                </tag>
              </tags>
            </configuration>
            <executions>
              <execution>
                <id>attach-javadocs</id>
                <phase>package</phase>
                <goals>
                  <goal>jar</goal>
                </goals>
                <configuration>
                  <doclint>none</doclint>
                </configuration>
              </execution>
            </executions>
          </plugin>
          <!-- Gpg Signature -->
          <plugin>
            <groupId>org.apache.maven.plugins</groupId>
            <artifactId>maven-gpg-plugin</artifactId>
            <version>1.6</version>
            <executions>
              <execution>
                <!-- id 与 setting.xml 的 gpg 配置中的 id 对应-->
                <id>ossrh</id>
                <phase>verify</phase>
                <goals>
                  <goal>sign</goal>
                </goals>
              </execution>
            </executions>
          </plugin>
          <plugin>
            <groupId>org.sonatype.plugins</groupId>
            <artifactId>nexus-staging-maven-plugin</artifactId>
            <version>1.6.7</version>
            <extensions>true</extensions>
            <configuration>
              <!-- 与 setting.xml 的 server 配置中的 sonatype-release 对应-->
              <serverId>sonatype-release</serverId>
              <nexusUrl>https://s01.oss.sonatype.org/</nexusUrl>
              <autoReleaseAfterClose>true</autoReleaseAfterClose>
            </configuration>
          </plugin>
        </plugins>
      </build>
    </profile>
  </profiles>
  <!-- snapshot 快照版和 release 正式版的仓库地址 -->
  <distributionManagement>
    <snapshotRepository>
      <id>sonatype-snapshots</id>
      <url>https://s01.oss.sonatype.org/content/repositories/snapshots</url>
    </snapshotRepository>
    <repository>
      <id>sonatype-release</id>
      <url>https://s01.oss.sonatype.org/service/local/staging/deploy/maven2/</url>
    </repository>
  </distributionManagement>
</project>
