<?xml version="1.0" encoding="UTF-8"?>
<project xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://maven.apache.org/POM/4.0.0"
         xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 https://maven.apache.org/xsd/maven-4.0.0.xsd">
    <modelVersion>4.0.0</modelVersion>

    <groupId>bg.codexio.springframework.boot</groupId>
    <artifactId>spring-boot-starter-requery</artifactId>
    <version>1.0.2</version>
    <packaging>jar</packaging>

    <name>Codexio Ltd. Spring Boot starter for Unified Request to Query resolver</name>
    <description>Spring Boot starter for Unified Request to Query resolver</description>
    <url>https://github.com/CodexioLtd/spring-boot-starter-requery</url>

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

    <developers>
        <developer>
            <name>Codexio Team</name>
            <email>info@codexio.bg</email>
            <organization>Codexio Ltd.</organization>
            <organizationUrl>https://codexio.bg</organizationUrl>
        </developer>
    </developers>

    <scm>
        <connection>scm:git:git://github.com/CodexioLtd/spring-boot-starter-requery.git</connection>
        <developerConnection>scm:git:ssh://github.com:CodexioLtd/spring-boot-starter-requery.git</developerConnection>
        <url>https://github.com/CodexioLtd/spring-boot-starter-requery/tree/master</url>
    </scm>

    <properties>
        <java.version>21</java.version>
        <codexio.requery.version>1.0.3</codexio.requery.version>

        <maven.compiler.version>3.12.1</maven.compiler.version>
        <nexus.plugin.version>1.6.13</nexus.plugin.version>
        <gpg.plugin.version>3.1.0</gpg.plugin.version>
        <javadoc.plugin.version>3.6.3</javadoc.plugin.version>
        <source.plugin.version>3.3.0</source.plugin.version>
    </properties>

    <dependencies>
        <dependency>
            <groupId>bg.codexio.springframework.data.jpa.requery</groupId>
            <artifactId>requery-core</artifactId>
            <version>${codexio.requery.version}</version>
        </dependency>
    </dependencies>

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

    <build>
        <plugins>
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-compiler-plugin</artifactId>
                <version>${maven.compiler.version}</version>
                <configuration>
                    <source>${java.version}</source>
                    <target>${java.version}</target>
                </configuration>
            </plugin>
        </plugins>
    </build>

    <profiles>
        <profile>
            <id>mvn-deploy</id>
            <activation>
                <activeByDefault>false</activeByDefault>
            </activation>

            <build>
                <plugins>

                    <plugin>
                        <groupId>org.apache.maven.plugins</groupId>
                        <artifactId>maven-source-plugin</artifactId>
                        <version>${source.plugin.version}</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>${javadoc.plugin.version}</version>
                        <executions>
                            <execution>
                                <id>attach-javadocs</id>
                                <goals>
                                    <goal>jar</goal>
                                </goals>
                                <configuration>
                                    <failOnError>false</failOnError>
                                </configuration>
                            </execution>
                        </executions>
                    </plugin>

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

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

                </plugins>
            </build>
        </profile>
    </profiles>

</project>
