<?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 http://maven.apache.org/xsd/maven-4.0.0.xsd">
    <modelVersion>4.0.0</modelVersion>
    <groupId>works.nuka</groupId>
    <artifactId>ModularKit</artifactId>
    <version>1.8.2</version>
    <name>ModularKit</name>
    <url>https://modularkit.nuka.works</url>
    <description>
        ModularKit, an alternative to the OSGi framework, more lightweight and powerful Java toolkit for creating
        modular apps.
    </description>
    <licenses>
        <license>
            <name>BSD 3-Clause License</name>
            <url>https://raw.githubusercontent.com/NukaWorks/ModularKit/main/LICENSE</url>
            <distribution>repo</distribution>
        </license>
    </licenses>

    <organization>
        <name>NukaWorks</name>
        <url>https://nuka.works</url>
    </organization>

    <developers>
        <developer>
            <id>powerm1nt</id>
            <name>Powerm1nt</name>
            <email>leonard.chabot@nuka.works</email>
            <url>https://github.com/Powerm1nt</url>
            <organization>NukaWorks</organization>
            <organizationUrl>https://nuka.works</organizationUrl>
            <roles>
                <role>developer</role>
            </roles>
            <timezone>Europe/Paris</timezone>
        </developer>
    </developers>

    <scm>
        <connection>scm:git:https://github.com/NukaWorks/ModularKit.git</connection>
        <developerConnection>scm:git:https://github.com/NukaWorks/ModularKit.git</developerConnection>
        <tag>HEAD</tag>
        <url>scm:git:https://github.com/NukaWorks/ModularKit.git</url>
    </scm>

    <properties>
        <maven.compiler.source>23</maven.compiler.source>
        <maven.compiler.target>23</maven.compiler.target>
        <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
    </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>
        <testSourceDirectory>src/tests</testSourceDirectory>

        <plugins>
            <plugin>
                <version>3.13.0</version>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-compiler-plugin</artifactId>
                <configuration>
                    <source>23</source>
                    <target>23</target>
                    <compilerArgs>--enable-preview</compilerArgs>
                </configuration>
            </plugin>

            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-source-plugin</artifactId>
                <version>3.3.1</version>
                <executions>
                    <execution>
                        <id>attach-sources</id>
                        <goals>
                            <goal>jar</goal>
                        </goals>
                    </execution>
                </executions>
            </plugin>

            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-javadoc-plugin</artifactId>
                <version>3.10.1</version>
                <executions>
                    <execution>
                        <id>attach-javadocs</id>
                        <goals>
                            <goal>jar</goal>
                        </goals>
                    </execution>
                </executions>
            </plugin>

            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-assembly-plugin</artifactId>
                <version>3.7.0</version>
                <configuration>
                    <descriptorRefs>
                        <descriptorRef>jar-with-dependencies</descriptorRef>
                    </descriptorRefs>
                </configuration>
                <executions>
                    <execution>
                        <phase>package</phase>
                        <goals>
                            <goal>single</goal>
                        </goals>
                    </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>central</publishingServerId>
                    <autoPublish>true</autoPublish>
                </configuration>
            </plugin>

            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-gpg-plugin</artifactId>
                <version>3.2.6</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-surefire-plugin</artifactId>
                <version>3.5.2</version>
                <configuration>
                    <argLine>--enable-preview</argLine>
                </configuration>
            </plugin>
        </plugins>
        <finalName>${project.artifactId}-${project.version}</finalName>
    </build>

    <dependencies>
        <dependency>
            <groupId>com.google.code.gson</groupId>
            <artifactId>gson</artifactId>
            <version>2.12.1</version>
        </dependency>
        <dependency>
            <groupId>org.junit.jupiter</groupId>
            <artifactId>junit-jupiter-api</artifactId>
            <version>5.11.3</version>
            <scope>test</scope>
        </dependency>
        <dependency>
            <groupId>org.jetbrains</groupId>
            <artifactId>annotations</artifactId>
            <version>26.0.2</version>
            <scope>compile</scope>
        </dependency>
    </dependencies>
</project>
