<?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>io.github.danfromtitan</groupId>
  <artifactId>test-bundle</artifactId>
  <version>1.0.45</version>
  <packaging>jar</packaging>

  <name>test-bundle</name>
  <description>Central Portal deployment test</description>
  <url>https://github.com/danfromtitan/test-bundle.git</url>

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

  <developers>
    <developer>
      <name>Dan Constantinescu</name>
      <email>nouser@nodomain.com</email>
      <organization>Sonatype</organization>
      <organizationUrl>https://www.sonatype.com</organizationUrl>
    </developer>
  </developers>

  <scm>
    <connection>scm:git:git://github.com/danfromtitan/test-bundle.git</connection>
    <developerConnection>scm:git:ssh:github.com:danfromtitan/test-bundle.git</developerConnection>
    <url>https://github.com/danfromtitan/test-bundle.git</url>
    <tag>${project.artifactId}-${project.version}</tag>
  </scm>

  <properties>
    <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
    <tokenAuth>true</tokenAuth>
    <deploymentName>${project.artifactId}-${project.version}</deploymentName>

    <publishing.server.id>portal-production</publishing.server.id>
    <centralBaseUrl>https://central.sonatype.com</centralBaseUrl>
    <!---
    <publishing.server.id>portal-develop</publishing.server.id>
    <centralBaseUrl>https://central.sonatype.dev</centralBaseUrl>

    <publishing.server.id>portal-staging</publishing.server.id>
    <centralBaseUrl>https://staging.portal.central.sonatype.dev</centralBaseUrl>
    -->

  </properties>

<!--
<distributionManagement>
<snapshotRepository>
  <id>ossrh</id>
  <url>https://s01.oss.sonatype.org/content/repositories/snapshots</url>
</snapshotRepository>
<repository>
  <id>ossrh</id>
  <url>https://s01.oss.sonatype.org/service/local/staging/deploy/maven2/</url>
</repository>
</distributionManagement>
-->

  <build>
    <plugins>
      <!--
      <plugin>
        <groupId>org.sonatype.plugins</groupId>
        <artifactId>nexus-staging-maven-plugin</artifactId>
        <version>1.6.13</version>
        <extensions>true</extensions>
        <configuration>
          <serverId>ossrh</serverId>
          <nexusUrl>https://s01.oss.sonatype.org/</nexusUrl>
          <autoReleaseAfterClose>true</autoReleaseAfterClose>
        </configuration>
        <dependencies>
          <dependency>
            <groupId>com.thoughtworks.xstream</groupId>
            <artifactId>xstream</artifactId>
            <version>1.4.20</version>
          </dependency>
        </dependencies>
      </plugin>
      -->
      <plugin>
        <groupId>org.codehaus.mojo</groupId>
        <artifactId>build-helper-maven-plugin</artifactId>
        <version>3.4.0</version>
        <executions>
          <execution>
            <id>regex-property</id>
            <goals>
              <goal>regex-property</goal>
            </goals>
            <configuration>
              <name>project.groupId.path</name>
              <value>${project.groupId}</value>
              <regex>\.</regex>
              <replacement>/</replacement>
              <failIfNoMatch>true</failIfNoMatch>
            </configuration>
          </execution>
        </executions>
      </plugin>
      <plugin>
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-compiler-plugin</artifactId>
        <version>3.10.1</version>
        <configuration>
          <source>8</source>
          <target>8</target>
        </configuration>
      </plugin>
      <plugin>
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-source-plugin</artifactId>
        <version>2.2.1</version>
        <executions>
          <execution>
            <id>attach-sources</id>
            <goals>
              <goal>jar-no-fork</goal>
            </goals>
          </execution>
        </executions>
      </plugin>
      <plugin>
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-javadoc-plugin</artifactId>
        <version>3.5.0</version>
        <configuration>
          <source>8</source>
          <doclint>all,-missing</doclint>
        </configuration>
        <executions>
          <execution>
            <goals>
              <goal>jar</goal>
            </goals>
          </execution>
        </executions>
      </plugin>
      <plugin>
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-gpg-plugin</artifactId>
        <version>3.1.0</version>
        <executions>
          <execution>
            <id>sign-artifacts</id>
            <phase>verify</phase>
            <goals>
              <goal>sign</goal>
            </goals>
            <configuration>
              <excludes>
                <exclude>**/*.zip</exclude>
              </excludes>
              <keyname>0A3B2341C2B63BE7AEB49CDC6EF0E1037D1BD5D4</keyname>
              <gpgArguments>
                <arg>--pinentry-mode</arg>
                <arg>loopback</arg>
              </gpgArguments>
            </configuration>
          </execution>
        </executions>
      </plugin>
      <!--
      <plugin>
        <groupId>net.nicoulaj.maven.plugins</groupId>
        <artifactId>checksum-maven-plugin</artifactId>
        <version>1.11</version>
        <executions>
          <execution>
            <id>checksum-maven-plugin-files</id>
            <phase>package</phase>
            <goals>
              <goal>files</goal>
            </goals>
          </execution>
        </executions>
        <configuration>
          <fileSets>
            <fileSet>
              <directory>${project.build.directory}</directory>
              <includes>
                <include>**/*.asc</include>
                <include>**/*.jar</include>
                <include>**/*.pom</include>
              </includes>
            </fileSet>
          </fileSets>
          <algorithms>
            <algorithm>MD5</algorithm>
            <algorithm>SHA-1</algorithm>
          </algorithms>
          <csvSummary>false</csvSummary>
          <csvSummaryFile>artifacts-checksums.csv</csvSummaryFile>
        </configuration>
      </plugin>
      <plugin>
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-assembly-plugin</artifactId>
        <version>3.6.0</version>
        <executions>
          <execution>
            <phase>package</phase>
            <goals>
              <goal>single</goal>
            </goals>
            <configuration>
              <appendAssemblyId>false</appendAssemblyId>
              <descriptors>
                <descriptor>src/main/assembly/zip.xml</descriptor>
              </descriptors>
            </configuration>
          </execution>
        </executions>
      </plugin>
      -->
      <plugin>
        <groupId>org.sonatype.central</groupId>
        <artifactId>central-publishing-maven-plugin</artifactId>
        <version>0.7.0</version>
        <extensions>true</extensions>
        <configuration>
          <publishingServerId>portal-production</publishingServerId>
          <autoPublish>true</autoPublish>
          <waitUntil>uploaded</waitUntil>
        </configuration>
      </plugin>

    </plugins>
  </build>

</project>
