<?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.qixils.crowdcontrol</groupId>
    <artifactId>java-crowd-control</artifactId>
    <version>3.1.0</version> <!-- don't forget to update scm tag -->

    <name>java-crowd-control</name>
    <description>Library for interacting with a crowdcontrol.live server</description>
    <url>https://github.com/qixils/java-crowd-control</url>
    <scm>
        <connection>scm:git:https://github.com/qixils/java-crowd-control</connection>
        <developerConnection>scm:git:https://github.com/qixils/java-crowd-control</developerConnection>
        <url>https://github.com/qixils/java-crowd-control.git</url>
        <tag>v3.1.0</tag>
    </scm>
    <licenses>
        <license>
            <name>MIT License</name>
            <url>https://github.com/qixils/java-crowd-control/blob/master/LICENSE</url>
            <distribution>repo</distribution>
            <comments>A short and simple permissive license</comments>
        </license>
    </licenses>
    <developers>
        <developer>
            <id>qixils</id>
            <name>Lexi Larkin</name>
            <email>lexi@qixils.dev</email>
            <url>https://qixils.dev/</url>
            <roles>
                <role>developer</role>
            </roles>
            <timezone>America/New_York</timezone>
            <properties>
                <picUrl>https://i.qixils.dev/avatar.png</picUrl>
                <twitter>lexikiq</twitter>
                <github>qixils</github>
                <gitlab>lexikiq</gitlab>
            </properties>
        </developer>
    </developers>

    <properties>
        <java.version>11</java.version>
        <maven.compiler.source>${java.version}</maven.compiler.source>
        <maven.compiler.target>${java.version}</maven.compiler.target>
        <maven.compiler.release>${java.version}</maven.compiler.release>
    </properties>

    <build>
        <sourceDirectory>src/main/java</sourceDirectory>
        <plugins>
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-source-plugin</artifactId>
                <version>3.2.0</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.1</version>
                <executions>
                    <execution>
                        <id>attach-javadocs</id>
                        <goals>
                            <goal>jar</goal>
                        </goals>
                    </execution>
                </executions>
            </plugin>
        </plugins>
    </build>

    <dependencies>
        <dependency>
            <groupId>com.google.code.gson</groupId>
            <artifactId>gson</artifactId>
            <version>2.8.9</version>
        </dependency>
        <dependency>
            <groupId>org.jetbrains</groupId>
            <artifactId>annotations</artifactId>
            <version>22.0.0</version>
        </dependency>
        <dependency>
            <groupId>com.google.code.findbugs</groupId>
            <artifactId>jsr305</artifactId>
            <version>3.0.2</version>
        </dependency>
    </dependencies>

    <profiles>
        <profile>
            <id>publish</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>
                                    <!-- Prevent gpg from using pinentry programs -->
                                    <gpgArguments>
                                        <arg>--pinentry-mode</arg>
                                        <arg>loopback</arg>
                                    </gpgArguments>
                                </configuration>
                            </execution>
                        </executions>
                    </plugin>
                </plugins>
            </build>
        </profile>
        <profile>
            <id>github</id>
            <distributionManagement>
                <repository>
                    <id>github</id>
                    <name>GitHub qixils Apache Maven Packages</name>
                    <url>https://maven.pkg.github.com/qixils/java-crowd-control</url>
                </repository>
            </distributionManagement>
        </profile>
        <profile>
            <id>ossrh</id>
            <distributionManagement>
                <repository>
                    <id>ossrh</id>
                    <url>https://s01.oss.sonatype.org/service/local/staging/deploy/maven2/</url>
                </repository>
                <snapshotRepository>
                    <id>ossrh</id>
                    <url>https://s01.oss.sonatype.org/content/repositories/snapshots</url>
                </snapshotRepository>
            </distributionManagement>
        </profile>
    </profiles>

</project>