<?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>com.commandhelper</groupId>
	<artifactId>PacketJumper</artifactId>
	<version>1.0.0-SNAPSHOT</version>
	<packaging>jar</packaging>
	<properties>
		<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
		<maven.compiler.source>17</maven.compiler.source>
		<maven.compiler.target>17</maven.compiler.target>
		<exec.mainClass>com.commandhelper.packetjumper.PacketJumper</exec.mainClass>
	</properties>
	<build>
		<plugins>
			<!-- Leave this alone! Compile-time checks so that your extension works. -->
			<plugin>
				<groupId>org.bsc.maven</groupId>
				<artifactId>maven-processor-plugin</artifactId>
				<version>2.2.4</version>

				<executions>
					<execution>
						<id>process</id>
						<phase>process-classes</phase>


						<goals>
							<goal>process</goal>
						</goals>
					</execution>
				</executions>


				<configuration>
					<outputDirectory>src/main/generated</outputDirectory>


					<processors>
						<processor>com.laytonsmith.core.extensions.ExtensionAnnotationProcessor</processor>
					</processors>
				</configuration>
			</plugin>


			<!-- Leave this alone! Run-time extension loading speedup. -->
			<plugin>
				<groupId>org.codehaus.mojo</groupId>
				<artifactId>exec-maven-plugin</artifactId>
				<version>1.2.1</version>


				<executions>
					<execution>
						<id>cache-annotations</id>
						<phase>process-classes</phase>
						<goals>
							<goal>java</goal>
						</goals>
					</execution>
				</executions>


				<configuration>
					<mainClass>com.laytonsmith.PureUtilities.ClassLoading.Annotations.CacheAnnotations</mainClass>


					<arguments>
						<argument>${basedir}/target/classes</argument>
						<argument>${basedir}/target/classes</argument>
					</arguments>
				</configuration>
			</plugin>

			<!-- Shade plugin -->
			<plugin>
				<groupId>org.apache.maven.plugins</groupId>
				<artifactId>maven-shade-plugin</artifactId>
				<version>3.3.0</version>
				<executions>
					<execution>
						<id>ShadedBundle</id>
						<phase>package</phase>
						<goals>
							<goal>shade</goal>
						</goals>
						<configuration>
							<shadedArtifactAttached>true</shadedArtifactAttached>
							<shadedClassifierName>full</shadedClassifierName>
							<minimizeJar>false</minimizeJar>
							<artifactSet>
								<includes>
									<include>net.fabricmc:mapping-io:jar:*</include>
								</includes>
							</artifactSet>
							<relocations>
								<relocation>
									<pattern>net.fabricmc</pattern>
									<shadedPattern>com.commandhelper.libs.net.fabricmc</shadedPattern>
								</relocation>
							</relocations>
							<filters>
								<filter>
									<artifact>net.fabricmc:mapping-io:jar:*</artifact>
									<includes>
										<include>**</include>
									</includes>
									<excludes>
										<exclude>META-INF/**</exclude>
									</excludes>
								</filter>
							</filters>
						</configuration>
					</execution>
				</executions>
			</plugin>
		</plugins>
	</build>
	<repositories>
		<repository>
			<id>dmulloy2-repo</id>
			<url>https://repo.dmulloy2.net/repository/public/</url>
		</repository>
	</repositories>
    <dependencies>
        <dependency>
            <groupId>com.sk89q</groupId>
            <artifactId>commandhelper</artifactId>
            <version>3.3.5-SNAPSHOT</version>
			<classifier>full</classifier>
        </dependency>
		<!-- GPL-2.0 -->
		<dependency>
			<groupId>com.comphenix.protocol</groupId>
			<artifactId>ProtocolLib</artifactId>
			<version>5.2.0-SNAPSHOT</version>
		</dependency>
		<!-- Apache 2.0 -->
		<dependency>
			<groupId>net.fabricmc</groupId>
			<artifactId>mapping-io</artifactId>
			<version>0.5.1</version>
		</dependency>
    </dependencies>
</project>