add OkHttp

This commit is contained in:
minster586
2025-06-19 19:08:44 -04:00
parent f02cb847c1
commit 58ad730c99
2 changed files with 21 additions and 11 deletions

1
.gitignore vendored Normal file
View File

@@ -0,0 +1 @@
dependency-reduced-pom.xml

31
pom.xml
View File

@@ -1,4 +1,4 @@
<project xmlns="http://maven.apache.org/POM/4.0.0" <project xmlns="http://maven.apache.org/POM/4.0.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="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"> https://maven.apache.org/xsd/maven-4.0.0.xsd">
@@ -6,11 +6,12 @@
<groupId>com.smartcraft.notifier</groupId> <groupId>com.smartcraft.notifier</groupId>
<artifactId>SmartCraftNotifier</artifactId> <artifactId>SmartCraftNotifier</artifactId>
<version>1.0.0</version> <version>1.0.1</version>
<name>SmartCraftNotifier</name> <name>SmartCraftNotifier</name>
<build> <build>
<plugins> <plugins>
<!-- Java Compiler -->
<plugin> <plugin>
<groupId>org.apache.maven.plugins</groupId> <groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-compiler-plugin</artifactId> <artifactId>maven-compiler-plugin</artifactId>
@@ -21,17 +22,22 @@
</configuration> </configuration>
</plugin> </plugin>
<!-- Shade plugin to bundle OkHttp -->
<plugin> <plugin>
<groupId>org.apache.maven.plugins</groupId> <groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-jar-plugin</artifactId> <artifactId>maven-shade-plugin</artifactId>
<version>3.3.0</version> <version>3.5.0</version>
<configuration> <executions>
<archive> <execution>
<manifest> <phase>package</phase>
<mainClass>com.smartcraft.notifier.SmartCraftNotifier</mainClass> <goals>
</manifest> <goal>shade</goal>
</archive> </goals>
</configuration> <configuration>
<minimizeJar>true</minimizeJar>
</configuration>
</execution>
</executions>
</plugin> </plugin>
</plugins> </plugins>
</build> </build>
@@ -44,12 +50,15 @@
</repositories> </repositories>
<dependencies> <dependencies>
<!-- Spigot API -->
<dependency> <dependency>
<groupId>org.spigotmc</groupId> <groupId>org.spigotmc</groupId>
<artifactId>spigot-api</artifactId> <artifactId>spigot-api</artifactId>
<version>1.20-R0.1-SNAPSHOT</version> <version>1.20-R0.1-SNAPSHOT</version>
<scope>provided</scope> <scope>provided</scope>
</dependency> </dependency>
<!-- OkHttp (will be shaded) -->
<dependency> <dependency>
<groupId>com.squareup.okhttp3</groupId> <groupId>com.squareup.okhttp3</groupId>
<artifactId>okhttp</artifactId> <artifactId>okhttp</artifactId>