<?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.hakky54</groupId>
    <artifactId>sslcontext-kickstart-bom</artifactId>
    <version>8.2.0</version>
    <packaging>pom</packaging>

    <name>SSLContext Kickstart (Bill Of Materials)</name>
    <description>SSLContext Kickstart (Bill Of Materials)</description>
    <url>https://github.com/Hakky54/sslcontext-kickstart</url>

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

    <scm>
        <url>https://github.com/Hakky54/sslcontext-kickstart</url>
        <connection>scm:git:git@github.com:Hakky54/sslcontext-kickstart.git</connection>
        <developerConnection>scm:git:git@github.com:Hakky54/sslcontext-kickstart.git</developerConnection>
        <tag>v8.2.0</tag>
    </scm>

    <developers>
        <developer>
            <id>Hakky54</id>
            <name>Hakan Altindag</name>
            <organization>Thunderberry</organization>
            <url>https://github.com/Hakky54</url>
            <roles>
                <role>Maintainer</role>
            </roles>
        </developer>
    </developers>

    <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>

    <properties>
        <version.maven-compiler-plugin>3.11.0</version.maven-compiler-plugin>
        <version.maven-gpg-plugin>3.1.0</version.maven-gpg-plugin>
        <version.maven-release-plugin>3.0.1</version.maven-release-plugin>
        <version.nexus-staging-maven-plugin>1.6.13</version.nexus-staging-maven-plugin>
        <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
    </properties>

    <dependencyManagement>
        <dependencies>
            <dependency>
                <groupId>io.github.hakky54</groupId>
                <artifactId>sslcontext-kickstart</artifactId>
                <version>${project.version}</version>
            </dependency>
            <dependency>
                <groupId>io.github.hakky54</groupId>
                <artifactId>sslcontext-kickstart-for-netty</artifactId>
                <version>${project.version}</version>
            </dependency>
            <dependency>
                <groupId>io.github.hakky54</groupId>
                <artifactId>sslcontext-kickstart-for-jetty</artifactId>
                <version>${project.version}</version>
            </dependency>
            <dependency>
                <groupId>io.github.hakky54</groupId>
                <artifactId>sslcontext-kickstart-for-apache4</artifactId>
                <version>${project.version}</version>
            </dependency>
            <dependency>
                <groupId>io.github.hakky54</groupId>
                <artifactId>sslcontext-kickstart-for-apache5</artifactId>
                <version>${project.version}</version>
            </dependency>
            <dependency>
                <groupId>io.github.hakky54</groupId>
                <artifactId>sslcontext-kickstart-for-pem</artifactId>
                <version>${project.version}</version>
            </dependency>
        </dependencies>
    </dependencyManagement>

    <build>
        <plugins>
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-compiler-plugin</artifactId>
                <version>${version.maven-compiler-plugin}</version>
                <executions>
                    <execution>
                        <id>default-compile</id>
                    </execution>
                    <execution>
                        <id>java8-compile</id>
                        <goals>
                            <goal>compile</goal>
                        </goals>
                        <!-- recompile everything with Java 8 except the module-info.java -->
                        <configuration>
                            <release>8</release>
                            <excludes>
                                <exclude>module-info.java</exclude>
                            </excludes>
                        </configuration>
                    </execution>
                </executions>
                <configuration>
                    <release>11</release>
                    <source>11</source>
                    <target>11</target>
                </configuration>
            </plugin>

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

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

    <profiles>
        <profile>
            <id>ossrh</id>
            <build>
                <plugins>
                    <plugin>
                        <groupId>org.apache.maven.plugins</groupId>
                        <artifactId>maven-gpg-plugin</artifactId>
                        <version>${version.maven-gpg-plugin}</version>
                        <configuration>
                            <executable>gpg</executable>
                            <keyname>${gpg.keyname}</keyname>
                            <passphraseServerId>${gpg.keyname}</passphraseServerId>
                        </configuration>
                        <executions>
                            <execution>
                                <id>sign-artifacts</id>
                                <phase>verify</phase>
                                <goals>
                                    <goal>sign</goal>
                                </goals>
                            </execution>
                        </executions>
                    </plugin>
                </plugins>
            </build>
        </profile>
    </profiles>

</project>
