<?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>dev.struchkov.godfather</groupId>
    <artifactId>godfather-bot</artifactId>
    <version>0.0.65</version>
    <packaging>pom</packaging>

    <modules>
        <module>bot-context</module>
        <module>bot-core</module>
        <module>bot-data</module>
        <module>bot-exception</module>
        <module>bot-domain</module>
    </modules>

    <name>GodFather Bot</name>
    <description>Абстрактная библиотека для помощи в реализации библиотек ботов для конкретных социальных сетей
    </description>
    <url>https://github.com/Godfather-Bots/godfather</url>
    <licenses>
        <license>
            <name>BSD 3-Clause "New" or "Revised" License</name>
            <url>https://github.com/Godfather-Bots/godfather/blob/master/LICENSE</url>
        </license>
    </licenses>

    <properties>
        <java.version>17</java.version>
        <maven.compiler.source>${java.version}</maven.compiler.source>
        <maven.compiler.target>${java.version}</maven.compiler.target>
        <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
        <project.reporting.outputEncoding>UTF-8</project.reporting.outputEncoding>

        <!-- https://mvnrepository.com/artifact/dev.struchkov.haiti/haiti-utils -->
        <haiti.utils>2.7.2</haiti.utils>

        <!-- https://mvnrepository.com/artifact/io.smallrye.reactive/smallrye-mutiny-vertx-core -->
        <smallrye.mutiny.vertx.core.version>2.30.1</smallrye.mutiny.vertx.core.version>

        <!-- https://mvnrepository.com/artifact/org.jetbrains/annotations -->
        <jetbrains.annotations.version>24.0.1</jetbrains.annotations.version>

        <!-- https://mvnrepository.com/artifact/org.apache.maven.plugins/maven-compiler-plugin -->
        <plugin.maven.compiler.ver>3.11.0</plugin.maven.compiler.ver>
        <!-- https://mvnrepository.com/artifact/org.sonatype.plugins/nexus-staging-maven-plugin -->
        <plugin.nexus.staging.ver>1.6.13</plugin.nexus.staging.ver>
        <!-- https://mvnrepository.com/artifact/org.apache.maven.plugins/maven-source-plugin -->
        <plugin.maven.source.ver>3.2.1</plugin.maven.source.ver>
        <!-- https://mvnrepository.com/artifact/org.apache.maven.plugins/maven-javadoc-plugin -->
        <plugin.maven.javadoc.ver>3.5.0</plugin.maven.javadoc.ver>
        <!-- https://mvnrepository.com/artifact/org.apache.maven.plugins/maven-gpg-plugin -->
        <plugin.maven.gpg.ver>3.0.1</plugin.maven.gpg.ver>
        <!-- https://mvnrepository.com/artifact/org.apache.maven.plugins/maven-release-plugin -->
        <plugin.maven.release.ver>3.0.0-M7</plugin.maven.release.ver>
    </properties>

    <dependencyManagement>
        <dependencies>
            <dependency>
                <groupId>dev.struchkov.godfather</groupId>
                <artifactId>bot-exception</artifactId>
                <version>${project.version}</version>
            </dependency>
            <dependency>
                <groupId>dev.struchkov.godfather</groupId>
                <artifactId>bot-domain-main</artifactId>
                <version>${project.version}</version>
            </dependency>
            <dependency>
                <groupId>dev.struchkov.godfather</groupId>
                <artifactId>bot-domain-quarkus</artifactId>
                <version>${project.version}</version>
            </dependency>
            <dependency>
                <groupId>dev.struchkov.godfather</groupId>
                <artifactId>bot-domain-simple</artifactId>
                <version>${project.version}</version>
            </dependency>

            <dependency>
                <groupId>dev.struchkov.godfather</groupId>
                <artifactId>bot-context-main</artifactId>
                <version>${project.version}</version>
            </dependency>
            <dependency>
                <groupId>dev.struchkov.godfather</groupId>
                <artifactId>bot-context-quarkus</artifactId>
                <version>${project.version}</version>
            </dependency>
            <dependency>
                <groupId>dev.struchkov.godfather</groupId>
                <artifactId>bot-context-simple</artifactId>
                <version>${project.version}</version>
            </dependency>

            <dependency>
                <groupId>dev.struchkov.godfather</groupId>
                <artifactId>bot-core-main</artifactId>
                <version>${project.version}</version>
            </dependency>
            <dependency>
                <groupId>dev.struchkov.godfather</groupId>
                <artifactId>bot-core-simple</artifactId>
                <version>${project.version}</version>
            </dependency>
            <dependency>
                <groupId>dev.struchkov.godfather</groupId>
                <artifactId>bot-core-quarkus</artifactId>
                <version>${project.version}</version>
            </dependency>

            <dependency>
                <groupId>dev.struchkov.godfather</groupId>
                <artifactId>bot-data-main</artifactId>
                <version>${project.version}</version>
            </dependency>
            <dependency>
                <groupId>dev.struchkov.godfather</groupId>
                <artifactId>bot-data-simple</artifactId>
                <version>${project.version}</version>
            </dependency>
            <dependency>
                <groupId>dev.struchkov.godfather</groupId>
                <artifactId>bot-data-quarkus</artifactId>
                <version>${project.version}</version>
            </dependency>

            <dependency>
                <groupId>dev.struchkov.haiti</groupId>
                <artifactId>haiti-utils</artifactId>
                <version>${haiti.utils}</version>
            </dependency>

            <dependency>
                <groupId>io.smallrye.reactive</groupId>
                <artifactId>smallrye-mutiny-vertx-core</artifactId>
                <version>${smallrye.mutiny.vertx.core.version}</version>
            </dependency>

            <dependency>
                <groupId>org.jetbrains</groupId>
                <artifactId>annotations</artifactId>
                <version>${jetbrains.annotations.version}</version>
            </dependency>

            <!-- https://mvnrepository.com/artifact/com.fasterxml.jackson.core/jackson-databind -->
            <dependency>
                <groupId>com.fasterxml.jackson.core</groupId>
                <artifactId>jackson-databind</artifactId>
                <version>2.14.2</version>
            </dependency>
        </dependencies>
    </dependencyManagement>

    <dependencies>
        <dependency>
            <groupId>org.projectlombok</groupId>
            <artifactId>lombok</artifactId>
            <version>1.18.26</version>
            <optional>true</optional>
        </dependency>
    </dependencies>

    <build>
        <pluginManagement>
            <plugins>
                <plugin>
                    <groupId>org.sonatype.plugins</groupId>
                    <artifactId>nexus-staging-maven-plugin</artifactId>
                    <version>${plugin.nexus.staging.ver}</version>
                    <extensions>true</extensions>
                </plugin>
                <plugin>
                    <groupId>org.apache.maven.plugins</groupId>
                    <artifactId>maven-compiler-plugin</artifactId>
                    <version>${plugin.maven.compiler.ver}</version>
                    <configuration>
                        <source>${java.version}</source>
                        <target>${java.version}</target>
                    </configuration>
                </plugin>
                <plugin>
                    <groupId>org.apache.maven.plugins</groupId>
                    <artifactId>maven-source-plugin</artifactId>
                    <version>${plugin.maven.source.ver}</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>${plugin.maven.javadoc.ver}</version>
                    <executions>
                        <execution>
                            <id>attach-javadocs</id>
                            <goals>
                                <goal>jar</goal>
                            </goals>
                        </execution>
                    </executions>
                </plugin>
                <plugin>
                    <groupId>org.apache.maven.plugins</groupId>
                    <artifactId>maven-gpg-plugin</artifactId>
                    <version>${plugin.maven.gpg.ver}</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>${plugin.maven.release.ver}</version>
                    <configuration>
                        <preparationGoals>clean install</preparationGoals>
                        <tagNameFormat>v.@{project.version}</tagNameFormat>
                        <autoVersionSubmodules>true</autoVersionSubmodules>
                        <pushChanges>false</pushChanges>
                        <localCheckout>true</localCheckout>
                        <signTag>true</signTag>
                    </configuration>
                </plugin>
            </plugins>
        </pluginManagement>

        <plugins>
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-release-plugin</artifactId>
            </plugin>
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-compiler-plugin</artifactId>
            </plugin>
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-javadoc-plugin</artifactId>
            </plugin>
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-source-plugin</artifactId>
            </plugin>
        </plugins>
    </build>

    <profiles>
        <profile>
            <id>release</id>
            <build>
                <plugins>
                    <plugin>
                        <groupId>org.sonatype.plugins</groupId>
                        <artifactId>nexus-staging-maven-plugin</artifactId>
                        <configuration>
                            <serverId>ossrh</serverId>
                            <nexusUrl>https://s01.oss.sonatype.org/</nexusUrl>
                            <autoReleaseAfterClose>true</autoReleaseAfterClose>
                        </configuration>
                    </plugin>
                    <plugin>
                        <groupId>org.apache.maven.plugins</groupId>
                        <artifactId>maven-source-plugin</artifactId>
                    </plugin>
                    <plugin>
                        <groupId>org.apache.maven.plugins</groupId>
                        <artifactId>maven-gpg-plugin</artifactId>
                    </plugin>
                    <plugin>
                        <groupId>org.apache.maven.plugins</groupId>
                        <artifactId>maven-javadoc-plugin</artifactId>
                    </plugin>
                </plugins>
            </build>
        </profile>
        <profile>
            <id>release-struchkov-nexus</id>
            <build>
                <plugins>
                    <plugin>
                        <groupId>org.sonatype.plugins</groupId>
                        <artifactId>nexus-staging-maven-plugin</artifactId>
                        <configuration>
                            <serverId>struchkov-nexus</serverId>
                            <nexusUrl>https://nexus.struchkov.dev/nexus/</nexusUrl>
                            <autoReleaseAfterClose>true</autoReleaseAfterClose>
                            <skipStaging>true</skipStaging>
                        </configuration>
                    </plugin>
                    <plugin>
                        <groupId>org.apache.maven.plugins</groupId>
                        <artifactId>maven-source-plugin</artifactId>
                    </plugin>
                    <plugin>
                        <groupId>org.apache.maven.plugins</groupId>
                        <artifactId>maven-gpg-plugin</artifactId>
                    </plugin>
                    <plugin>
                        <groupId>org.apache.maven.plugins</groupId>
                        <artifactId>maven-javadoc-plugin</artifactId>
                    </plugin>
                </plugins>
            </build>
        </profile>
        <profile>
            <id>snapshot</id>
            <build>
                <plugins>
                    <plugin>
                        <groupId>org.sonatype.plugins</groupId>
                        <artifactId>nexus-staging-maven-plugin</artifactId>
                        <configuration>
                            <serverId>struchkov-nexus</serverId>
                            <nexusUrl>https://nexus.struchkov.dev/nexus/</nexusUrl>
                            <autoReleaseAfterClose>true</autoReleaseAfterClose>
                        </configuration>
                    </plugin>
                    <plugin>
                        <groupId>org.apache.maven.plugins</groupId>
                        <artifactId>maven-source-plugin</artifactId>
                    </plugin>
                    <plugin>
                        <groupId>org.apache.maven.plugins</groupId>
                        <artifactId>maven-javadoc-plugin</artifactId>
                    </plugin>
                </plugins>
            </build>
        </profile>
    </profiles>

    <repositories>
        <repository>
            <id>struchkov-nexus-release</id>
            <url>https://nexus.struchkov.dev/repository/maven-releases/</url>
            <releases>
                <enabled>true</enabled>
                <updatePolicy>always</updatePolicy>
                <checksumPolicy>fail</checksumPolicy>
            </releases>
            <snapshots>
                <enabled>false</enabled>
            </snapshots>
        </repository>
        <repository>
            <id>struchkov-nexus-snapshot</id>
            <url>https://nexus.struchkov.dev/repository/maven-snapshots/</url>
            <releases>
                <enabled>false</enabled>
            </releases>
            <snapshots>
                <enabled>true</enabled>
                <updatePolicy>always</updatePolicy>
                <checksumPolicy>warn</checksumPolicy>
            </snapshots>
        </repository>
    </repositories>

    <distributionManagement>
        <repository>
            <id>struchkov-nexus-release</id>
            <url>https://nexus.struchkov.dev/repository/maven-releases/</url>
        </repository>
        <snapshotRepository>
            <id>struchkov-nexus-snapshot</id>
            <url>https://nexus.struchkov.dev/repository/maven-snapshots/</url>
        </snapshotRepository>
    </distributionManagement>

    <scm>
        <connection>scm:git:ssh://git@git.struchkov.dev:222/Godfather-Bots/godfather.git</connection>
        <url>https://git.struchkov.dev/Godfather-Bots/godfather</url>
        <developerConnection>scm:git:ssh://git@git.struchkov.dev:222/Godfather-Bots/godfather.git</developerConnection>
        <tag>v.0.0.65</tag>
    </scm>

    <developers>
        <developer>
            <id>uPagge</id>
            <name>Struchkov Mark</name>
            <email>mark@struchkov.dev</email>
            <url>https://mark.struchkov.dev</url>
        </developer>
    </developers>

</project>