<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/maven-v4_0_0.xsd">

  <modelVersion>4.0.0</modelVersion>
  <groupId>com.github.songdongsheng</groupId>
  <artifactId>identifier</artifactId>
  <name>Trend sorted identifier</name>
  <version>2.3.0</version>

  <packaging>jar</packaging>

  <url>https://paraio.org</url>
  <description>TSID - a general-purpose trend sorted identifier generator.</description>

  <scm>
    <connection>scm:git:https://github.com/songdongsheng/tsid.git</connection>
    <developerConnection>scm:git:git@github.com:songdongsheng/tsid.git</developerConnection>
    <url>https://github.com/songdongsheng/tsid</url>
  </scm>

  <developers>
    <developer>
      <name>宋冬生</name>
      <email>songdongsheng@live.cn</email>
    </developer>
  </developers>

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

  <properties>
    <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
    <project.reporting.outputEncoding>UTF-8</project.reporting.outputEncoding>

    <maven.compiler.source>1.8</maven.compiler.source>
    <maven.compiler.target>1.8</maven.compiler.target>

    <!--
        https://repo.maven.apache.org/maven2/ch/qos/logback/logback-core/maven-metadata.xml
        https://repo.maven.apache.org/maven2/org/apache/maven/plugins/maven-compiler-plugin/maven-metadata.xml
        https://repo.maven.apache.org/maven2/org/apache/maven/plugins/maven-dependency-plugin/maven-metadata.xml
        https://repo.maven.apache.org/maven2/org/apache/maven/plugins/maven-gpg-plugin/maven-metadata.xml
        https://repo.maven.apache.org/maven2/org/apache/maven/plugins/maven-jar-plugin/maven-metadata.xml
        https://repo.maven.apache.org/maven2/org/apache/maven/plugins/maven-javadoc-plugin/maven-metadata.xml
        https://repo.maven.apache.org/maven2/org/apache/maven/plugins/maven-jxr-plugin/maven-metadata.xml
        https://repo.maven.apache.org/maven2/org/apache/maven/plugins/maven-pmd-plugin/maven-metadata.xml
        https://repo.maven.apache.org/maven2/org/apache/maven/plugins/maven-project-info-reports-plugin/maven-metadata.xml
        https://repo.maven.apache.org/maven2/org/apache/maven/plugins/maven-release-plugin/maven-metadata.xml
        https://repo.maven.apache.org/maven2/org/apache/maven/plugins/maven-shade-plugin/maven-metadata.xml
        https://repo.maven.apache.org/maven2/org/apache/maven/plugins/maven-site-plugin/maven-metadata.xml
        https://repo.maven.apache.org/maven2/org/apache/maven/plugins/maven-source-plugin/maven-metadata.xml
        https://repo.maven.apache.org/maven2/org/apache/maven/plugins/maven-surefire-plugin/maven-metadata.xml
        https://repo.maven.apache.org/maven2/org/mockito/mockito-core/maven-metadata.xml
        https://repo.maven.apache.org/maven2/org/openjdk/jmh/jmh-core/maven-metadata.xml
        https://repo.maven.apache.org/maven2/org/slf4j/slf4j-api/maven-metadata.xml
        https://repo.maven.apache.org/maven2/org/sonatype/plugins/nexus-staging-maven-plugin/maven-metadata.xml
        https://repo.maven.apache.org/maven2/org/testng/testng/maven-metadata.xml
        -->

    <logback.version>1.2.3</logback.version>
    <maven.compiler.version>3.7.0</maven.compiler.version>
    <maven.dependency.version>3.0.2</maven.dependency.version>
    <maven.gpg.version>1.6</maven.gpg.version>
    <maven.jar.version>3.0.2</maven.jar.version>
    <maven.javadoc.version>2.10.4</maven.javadoc.version>
    <maven.jxr.version>2.5</maven.jxr.version>
    <maven.pmd.version>3.8</maven.pmd.version>
    <maven.pir.version>2.9</maven.pir.version>
    <maven.release.version>2.5.3</maven.release.version>
    <maven.shade.version>3.1.0</maven.shade.version>
    <maven.site.version>3.6</maven.site.version>
    <maven.source.version>3.0.1</maven.source.version>
    <maven.sr.version>2.20.1</maven.sr.version>
    <mockito.version>2.12.0</mockito.version>
    <jmh.version>1.19</jmh.version>
    <slf4j.api.version>1.7.25</slf4j.api.version>
    <nexus.version>1.6.8</nexus.version>
    <testng.version>6.11</testng.version>
  </properties>

  <dependencies>
    <dependency>
      <groupId>org.testng</groupId>
      <artifactId>testng</artifactId>
      <version>${testng.version}</version>
      <scope>test</scope>
    </dependency>

    <dependency>
      <groupId>org.openjdk.jmh</groupId>
      <artifactId>jmh-generator-annprocess</artifactId>
      <version>${jmh.version}</version>
      <scope>test</scope>
    </dependency>
  </dependencies>

  <build>
    <finalName>${project.groupId}.${project.artifactId}-${project.version}</finalName>

    <plugins>
      <plugin>
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-compiler-plugin</artifactId>
        <version>${maven.compiler.version}</version>
        <configuration>
          <compilerArgs>
            <arg>-Xlint:unchecked</arg>
            <arg>-Xlint:deprecation</arg>
          </compilerArgs>
        </configuration>
      </plugin>

      <plugin>
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-jar-plugin</artifactId>
        <version>${maven.jar.version}</version>
      </plugin>

      <plugin>
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-javadoc-plugin</artifactId>
        <version>${maven.javadoc.version}</version>
        <executions>
          <execution>
            <goals>
              <goal>jar</goal>
            </goals>
          </execution>
        </executions>
      </plugin>

      <plugin>
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-source-plugin</artifactId>
        <version>${maven.source.version}</version>
        <executions>
          <execution>
            <goals>
              <goal>jar-no-fork</goal>
            </goals>
          </execution>
        </executions>
      </plugin>

      <plugin>
        <artifactId>maven-dependency-plugin</artifactId>
        <version>${maven.dependency.version}</version>
        <executions>
          <execution>
            <goals>
              <goal>analyze-dep-mgt</goal>
              <goal>analyze-duplicate</goal>
              <goal>analyze-only</goal>
              <goal>copy-dependencies</goal>
              <goal>tree</goal>
            </goals>
            <configuration>
              <ignoredDependencies>
                <ignoredDependency>org.openjdk.jmh:jmh-core</ignoredDependency>
                <ignoredDependency>org.openjdk.jmh:jmh-generator-annprocess</ignoredDependency>
              </ignoredDependencies>
            </configuration>
          </execution>
        </executions>
      </plugin>

      <plugin>
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-gpg-plugin</artifactId>
        <version>${maven.gpg.version}</version>
        <executions>
          <execution>
            <id>sign-artifacts</id>
            <phase>verify</phase>
            <goals>
              <goal>sign</goal>
            </goals>
          </execution>
        </executions>
      </plugin>

      <plugin>
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-release-plugin</artifactId>
        <version>${maven.release.version}</version>
        <configuration>
          <tagNameFormat>@{project.version}</tagNameFormat>
          <preparationGoals>clean verify</preparationGoals>
        </configuration>
      </plugin>

      <plugin>
        <groupId>org.sonatype.plugins</groupId>
        <artifactId>nexus-staging-maven-plugin</artifactId>
        <version>${nexus.version}</version>
        <extensions>true</extensions>
        <configuration>
          <serverId>ossrh</serverId>
          <nexusUrl>https://oss.sonatype.org/</nexusUrl>
          <autoReleaseAfterClose>true</autoReleaseAfterClose>
        </configuration>
      </plugin>
    </plugins>
  </build>

  <reporting>
    <plugins>
      <plugin>
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-jxr-plugin</artifactId>
        <version>${maven.jxr.version}</version>
      </plugin>

      <plugin>
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-surefire-report-plugin</artifactId>
        <version>${maven.sr.version}</version>
      </plugin>

      <plugin>
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-pmd-plugin</artifactId>
        <version>${maven.pmd.version}</version>
        <configuration>
          <linkXRef>true</linkXRef>
          <sourceEncoding>utf-8</sourceEncoding>
        </configuration>
      </plugin>

      <plugin>
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-project-info-reports-plugin</artifactId>
        <version>${maven.pir.version}</version>
      </plugin>
    </plugins>
  </reporting>

  <distributionManagement>
    <snapshotRepository>
      <id>ossrh</id>
      <url>http://oss.sonatype.org/content/repositories/snapshots</url>
    </snapshotRepository>

    <repository>
      <id>ossrh</id>
      <url>http://oss.sonatype.org/service/local/staging/deploy/maven2/</url>
    </repository>
  </distributionManagement>
</project>
