<?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.pinkolik</groupId>
    <artifactId>general-classes-generator</artifactId>
    <packaging>pom</packaging>
    <version>1.1.3-RELEASE</version>
    <modules>
        <module>general-classes-generator-maven-plugin</module>
        <module>general-classes-generator-conversion</module>
        <module>general-classes-generator-tests</module>
    </modules>

    <name>General Class Generator</name>

    <description>
        This is the parent pom for such dependencies as
        general-classes-generator-conversion and
        general-classes-generator-maven-plugin.
    </description>

    <url>https://github.com/Pinkolik/general-classes-generator</url>

    <issueManagement>
        <system>GitHub Issues</system>
        <url>https://github.com/Pinkolik/general-classes-generator/issues</url>
    </issueManagement>

    <inceptionYear>2021</inceptionYear>

    <licenses>
        <license>
            <name>MIT License</name>
            <url>https://opensource.org/licenses/MIT</url>
            <distribution>repo</distribution>
        </license>
    </licenses>

    <scm>
        <url>https://github.com/Pinkolik/general-classes-generator</url>
        <connection>scm:git:git://github.com/Pinkolik/general-classes-generator.git</connection>
        <developerConnection>scm:git:git@github.com:Pinkolik/general-classes-generator.git</developerConnection>
    </scm>

    <developers>
        <developer>
            <email>mrpinkolik@gmail.com</email>
            <name>Simon Rusinov</name>
            <url>https://github.com/Pinkolik</url>
            <id>Pinkolik</id>
        </developer>
    </developers>

    <properties>
        <lombok.version>1.18.20</lombok.version>
        <slf4j-api.version>1.7.31</slf4j-api.version>
        <log4j-slf4j-impl.version>2.14.1</log4j-slf4j-impl.version>
        <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
    </properties>

    <build>
        <plugins>
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-compiler-plugin</artifactId>
                <version>3.8.1</version>
                <configuration>
                    <source>1.8</source>
                    <target>1.8</target>
                </configuration>
            </plugin>
        </plugins>
        <pluginManagement>
            <plugins>
                <plugin>
                    <groupId>org.apache.maven.plugins</groupId>
                    <artifactId>maven-surefire-plugin</artifactId>
                    <version>3.0.0-M5</version>
                </plugin>
                <plugin>
                    <groupId>org.apache.maven.plugins</groupId>
                    <artifactId>maven-source-plugin</artifactId>
                    <version>3.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.3.0</version>
                    <executions>
                        <execution>
                            <id>attach-javadocs</id>
                            <goals>
                                <goal>jar</goal>
                            </goals>
                        </execution>
                    </executions>
                </plugin>
            </plugins>
        </pluginManagement>
    </build>

    <dependencyManagement>
        <dependencies>
            <dependency>
                <groupId>org.slf4j</groupId>
                <artifactId>slf4j-api</artifactId>
                <version>${slf4j-api.version}</version>
            </dependency>
            <dependency>
                <groupId>org.projectlombok</groupId>
                <artifactId>lombok</artifactId>
                <version>${lombok.version}</version>
            </dependency>
            <dependency>
                <groupId>org.apache.logging.log4j</groupId>
                <artifactId>log4j-slf4j-impl</artifactId>
                <version>${log4j-slf4j-impl.version}</version>
            </dependency>
        </dependencies>
    </dependencyManagement>

    <profiles>
        <profile>
            <id>ci-cd</id>
            <build>
                <plugins>
                    <plugin>
                        <groupId>org.apache.maven.plugins</groupId>
                        <artifactId>maven-gpg-plugin</artifactId>
                        <version>3.0.1</version>
                        <executions>
                            <execution>
                                <id>sign-artifacts</id>
                                <phase>verify</phase>
                                <goals>
                                    <goal>sign</goal>
                                </goals>
                                <configuration>
                                    <gpgArguments>
                                        <!--NOTE: the pinentry-mode=loopback is necessary
                                         to avoid GPG prompting manual entry of the GPG passphrase.
                                         This is crucial when running your build on a remote agent!-->
                                        <arg>--pinentry-mode</arg>
                                        <arg>loopback</arg>
                                    </gpgArguments>
                                </configuration>
                            </execution>
                        </executions>
                    </plugin>
                </plugins>
            </build>
        </profile>
    </profiles>

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

</project>