1
mirror of https://github.com/CarmJos/EasyPlugin.git synced 2026-06-05 00:58:17 +08:00

Compare commits

...

19 Commits

Author SHA1 Message Date
carm ed505357f3 build(deploy): Fixed deployment 2025-05-20 09:38:11 +08:00
carm 54939f0f14 feat(users): Seperated users registry interface for api usage. 2025-05-17 03:44:07 +08:00
renovate[bot] bc3dd32f85 chore(deps): update dependency org.apache.maven.plugins:maven-compiler-plugin to v3.14.0 2025-03-12 04:38:25 +08:00
renovate[bot] 22ee1a157a chore(deps): update actions/checkout action to v4 2025-02-08 16:48:09 +08:00
renovate[bot] 00f1ff20fa chore(deps): update actions/setup-java action to v4 2025-02-08 16:48:06 +08:00
renovate[bot] 91136a506d chore(deps): update dependency org.apache.maven.plugins:maven-release-plugin to v3 2025-02-08 16:48:03 +08:00
renovate[bot] edb8e0849a chore(deps): update dependency org.apache.maven.plugins:maven-surefire-plugin to v3 2025-02-08 16:47:59 +08:00
renovate[bot] 4e6caae8c9 fix(deps): update dependency org.jetbrains:annotations to v26 2025-02-08 16:47:55 +08:00
renovate[bot] dd592cb764 fix(deps): update dependency me.clip:placeholderapi to v2.11.6 2025-02-07 02:25:20 +08:00
renovate[bot] 5784215209 chore(deps): update dependency org.apache.maven.plugins:maven-shade-plugin to v3.6.0 2025-02-06 22:12:03 +08:00
renovate[bot] 0eb774f560 chore(deps): update dependency org.apache.maven.plugins:maven-source-plugin to v3.3.1 2025-02-06 22:11:52 +08:00
renovate[bot] 4e24a87f12 chore(deps): update dependency org.apache.maven.plugins:maven-jar-plugin to v3.4.2 2025-02-06 22:10:13 +08:00
renovate[bot] 44357d401f chore(deps): update dependency org.apache.maven.plugins:maven-javadoc-plugin to v3.11.2 2025-02-06 22:10:09 +08:00
renovate[bot] d758e460f8 chore(deps): update dependency org.apache.maven.plugins:maven-compiler-plugin to v3.13.0 2025-02-06 21:44:39 +08:00
renovate[bot] 2caa33eb76 chore(deps): update dependency org.apache.maven.plugins:maven-gpg-plugin to v3.2.7 2025-02-06 21:44:36 +08:00
renovate[bot] 9450ef79fc chore(deps): update dependency org.apache.maven.plugins:maven-surefire-plugin to v2.22.2 2025-02-06 18:10:41 +08:00
renovate[bot] 89a17264f2 fix(deps): update dependency com.github.milkbowl:vaultapi to v1.7.1 2025-02-06 18:10:38 +08:00
renovate[bot] 7923de25fb Add renovate.json 2025-02-06 16:37:21 +08:00
carm bc046c02e4 fix(color): 修复ColorParse.clear功能异常的问题 2025-01-18 02:24:15 +08:00
27 changed files with 269 additions and 133 deletions
+10 -10
View File
@@ -14,9 +14,9 @@ jobs:
packages-deploy:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v4
- name: "Set up JDK"
uses: actions/setup-java@v2
uses: actions/setup-java@v4
with:
java-version: '8'
distribution: 'adopt'
@@ -35,9 +35,9 @@ jobs:
github-deploy:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v4
- name: "Set up JDK"
uses: actions/setup-java@v2
uses: actions/setup-java@v4
with:
java-version: '8'
distribution: 'adopt'
@@ -59,7 +59,7 @@ jobs:
run: |
rm -rf docs
mkdir -vp docs
cp -vrf target/site/apidocs/* docs/
cp -vrf target/reports/apidocs/* docs/
cp -vrf .documentation/javadoc/JAVADOC-README.md docs/README.md
- name: "Generate Javadoc sitemap"
@@ -112,21 +112,21 @@ jobs:
name: "Deploy Project (Central)"
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v4
- name: "Set up JDK"
uses: actions/setup-java@v2
uses: actions/setup-java@v4
with:
java-version: '11'
java-version: '8'
distribution: 'adopt'
cache: maven
server-id: ossrh
server-id: central
server-username: MAVEN_USERNAME
server-password: MAVEN_PASSWORD
gpg-private-key: ${{ secrets.MAVEN_GPG_PRIVATE_KEY }} # Value of the GPG private key to import
gpg-passphrase: MAVEN_GPG_PASSPHRASE # env variable for GPG private key passphrase
- name: "Central Deploy"
run: mvn -B -Possrh deploy --file pom.xml -DskipTests
run: mvn -B -Pcentral deploy --file pom.xml -DskipTests
env:
MAVEN_USERNAME: ${{ secrets.OSSRH_USER }}
MAVEN_PASSWORD: ${{ secrets.OSSRH_PASS }}
+2 -2
View File
@@ -14,9 +14,9 @@ jobs:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v4
- name: "Set up JDK"
uses: actions/setup-java@v2
uses: actions/setup-java@v4
with:
cache: maven
java-version: '8'
+1 -1
View File
@@ -6,7 +6,7 @@
<parent>
<groupId>cc.carm.lib</groupId>
<artifactId>easyplugin-parent</artifactId>
<version>1.5.12</version>
<version>1.5.13</version>
<relativePath>../../pom.xml</relativePath>
</parent>
<properties>
@@ -34,7 +34,7 @@ public class ColorParser {
public static @NotNull String clear(@NotNull String text) {
text = HEX_PATTERN.matcher(text).replaceAll("");
text = GRADIENT_PATTERN.matcher(text).replaceAll("");
text = COLOR_PATTERN.matcher(text).replaceAll("");
text = FORMAT_PATTERN.matcher(text).replaceAll("");
return text;
}
+1 -1
View File
@@ -19,7 +19,7 @@ public class ColorParseTest {
System.out.println(parse("&<#AAAAAA>&l我&r真&(#666666)的&<#BBBBBB>&o爱死&<#111111>你&<#FFFFFF>了&r"));
System.out.println(parse("&r正常的颜色理应&c&l不受影响&r。"));
System.out.println(clear("&f测试&<#AAAAAA>清理颜色代码&<#111111> &&这样应该&(#666666)不被影响 &f。"));
System.out.println(clear("&f&l测试&<#AAAAAA>清理颜色代码&<#111111> &&这样应该&(#666666)不被影响 &f。"));
}
}
+1 -1
View File
@@ -6,7 +6,7 @@
<parent>
<groupId>cc.carm.lib</groupId>
<artifactId>easyplugin-parent</artifactId>
<version>1.5.12</version>
<version>1.5.13</version>
<relativePath>../../pom.xml</relativePath>
</parent>
<properties>
+1 -1
View File
@@ -5,7 +5,7 @@
<parent>
<artifactId>easyplugin-parent</artifactId>
<groupId>cc.carm.lib</groupId>
<version>1.5.12</version>
<version>1.5.13</version>
<relativePath>../../pom.xml</relativePath>
</parent>
<modelVersion>4.0.0</modelVersion>
+1 -1
View File
@@ -5,7 +5,7 @@
<parent>
<artifactId>easyplugin-parent</artifactId>
<groupId>cc.carm.lib</groupId>
<version>1.5.12</version>
<version>1.5.13</version>
<relativePath>../../pom.xml</relativePath>
</parent>
<modelVersion>4.0.0</modelVersion>
@@ -6,6 +6,7 @@ import org.bukkit.event.HandlerList;
import org.bukkit.event.Listener;
import org.bukkit.event.inventory.InventoryClickEvent;
import org.bukkit.event.inventory.InventoryCloseEvent;
import org.bukkit.event.inventory.InventoryCreativeEvent;
import org.bukkit.event.inventory.InventoryDragEvent;
import org.bukkit.event.player.PlayerQuitEvent;
+21
View File
@@ -0,0 +1,21 @@
import org.junit.Test;
public class PageTest {
@Test
public void test() {
System.out.println(maxPage(0, 10));
System.out.println(maxPage(10, 10));
System.out.println(maxPage(5, 10));
System.out.println(maxPage(15, 10));
System.out.println(maxPage(19, 10));
System.out.println(maxPage(20, 10));
}
int maxPage(int contents, int size) {
if (contents == 0 || size == 0) return 1;
return (contents / size) + ((contents % size) == 0 ? 0 : 1);
}
}
+1 -1
View File
@@ -5,7 +5,7 @@
<parent>
<artifactId>easyplugin-parent</artifactId>
<groupId>cc.carm.lib</groupId>
<version>1.5.12</version>
<version>1.5.13</version>
<relativePath>../../pom.xml</relativePath>
</parent>
<modelVersion>4.0.0</modelVersion>
+1 -1
View File
@@ -6,7 +6,7 @@
<parent>
<groupId>cc.carm.lib</groupId>
<artifactId>easyplugin-parent</artifactId>
<version>1.5.12</version>
<version>1.5.13</version>
<relativePath>../../pom.xml</relativePath>
</parent>
<properties>
+1 -1
View File
@@ -5,7 +5,7 @@
<parent>
<artifactId>easyplugin-parent</artifactId>
<groupId>cc.carm.lib</groupId>
<version>1.5.12</version>
<version>1.5.13</version>
<relativePath>../../pom.xml</relativePath>
</parent>
<modelVersion>4.0.0</modelVersion>
+1 -1
View File
@@ -6,7 +6,7 @@
<parent>
<groupId>cc.carm.lib</groupId>
<artifactId>easyplugin-parent</artifactId>
<version>1.5.12</version>
<version>1.5.13</version>
<relativePath>../../pom.xml</relativePath>
</parent>
<properties>
@@ -0,0 +1,47 @@
package cc.carm.lib.easyplugin.user;
import org.jetbrains.annotations.NotNull;
import java.util.Objects;
public abstract class AbstractUserData<K> implements UserData<K> {
protected final @NotNull K key;
/**
* Used to mark the data as dropping (save and unload) status.
*/
protected boolean dropping = false;
protected AbstractUserData(@NotNull K key) {
this.key = key;
}
/**
* @param dropping true if the data is dropping, false otherwise
*/
public void setDropping(boolean dropping) {
this.dropping = dropping;
}
/**
* @return true if the data is dropping, false otherwise
*/
public boolean isDropping() {
return dropping;
}
@Override
public boolean equals(Object o) {
if (this == o) return true;
if (o == null || getClass() != o.getClass()) return false;
AbstractUserData<?> abstractUserData = (AbstractUserData<?>) o;
return key.equals(abstractUserData.key);
}
@Override
public int hashCode() {
return Objects.hash(key);
}
}
@@ -2,31 +2,22 @@ package cc.carm.lib.easyplugin.user;
import org.jetbrains.annotations.NotNull;
import java.util.Objects;
public interface UserData<K> {
public abstract class UserData<K> {
@NotNull K key();
protected final @NotNull K key;
protected UserData(@NotNull K key) {
this.key = key;
@Deprecated
default @NotNull K getKey() {
return key();
}
public @NotNull K getKey() {
return key;
}
@Override
public boolean equals(Object o) {
if (this == o) return true;
if (o == null || getClass() != o.getClass()) return false;
UserData<?> userData = (UserData<?>) o;
return key.equals(userData.key);
}
@Override
public int hashCode() {
return Objects.hash(key);
}
/**
* @param dropping true if the data is dropping, false otherwise
*/
void setDropping(boolean dropping);
/**
* @return true if the data is dropping, false otherwise
*/
boolean isDropping();
}
@@ -1,15 +1,12 @@
package cc.carm.lib.easyplugin.user;
import cc.carm.lib.easyplugin.EasyPlugin;
import com.google.common.collect.ImmutableSet;
import org.bukkit.Bukkit;
import org.bukkit.OfflinePlayer;
import org.bukkit.entity.Player;
import org.jetbrains.annotations.NotNull;
import org.jetbrains.annotations.Nullable;
import org.jetbrains.annotations.Unmodifiable;
import java.util.*;
import java.util.Collection;
import java.util.Collections;
import java.util.Map;
import java.util.concurrent.CompletableFuture;
import java.util.concurrent.ConcurrentHashMap;
import java.util.concurrent.ExecutorService;
@@ -21,7 +18,7 @@ import java.util.function.Supplier;
import java.util.logging.Logger;
import java.util.stream.Collectors;
public abstract class UserDataManager<K, U extends UserData<K>> {
public abstract class UserDataManager<K, U extends AbstractUserData<K>> implements UserDataRegistry<K, U> {
protected final @NotNull EasyPlugin plugin;
@@ -47,6 +44,7 @@ public abstract class UserDataManager<K, U extends UserData<K>> {
this.dataCache = cacheMap;
}
@Override
public void shutdown() {
this.executor.shutdown();
}
@@ -55,14 +53,11 @@ public abstract class UserDataManager<K, U extends UserData<K>> {
return plugin;
}
protected @NotNull Logger getLogger() {
@Override
public @NotNull Logger getLogger() {
return getPlugin().getLogger();
}
public String serializeKey(@NotNull K key) {
return key.toString();
}
public abstract @NotNull U emptyUser(@NotNull K key);
public @NotNull U errorUser(@NotNull K key) {
@@ -73,36 +68,16 @@ public abstract class UserDataManager<K, U extends UserData<K>> {
protected abstract void saveData(@NotNull U data) throws Exception;
public @NotNull CompletableFuture<U> load(@NotNull K key) {
return load(key, false);
}
public @NotNull CompletableFuture<U> load(@NotNull K key, boolean cache) {
return load(key, () -> cache);
}
public @NotNull Map<K, U> getDataCache() {
return dataCache;
}
@Unmodifiable
public @NotNull Set<U> list() {
return ImmutableSet.copyOf(getDataCache().values());
}
public @NotNull U get(@NotNull K key) {
return Optional.ofNullable(getNullable(key)).orElseThrow(() -> new NullPointerException("User " + key + " not found."));
}
public @Nullable U getNullable(@NotNull K key) {
return getDataCache().get(key);
}
public @NotNull Optional<@Nullable U> getOptional(@NotNull K key) {
return Optional.ofNullable(getNullable(key));
}
@Override
public @NotNull CompletableFuture<U> load(@NotNull K key, @NotNull Supplier<Boolean> cacheCondition) {
U cached = getNullable(key);
if (cached != null) {
return CompletableFuture.supplyAsync(() -> cached); // Return cached data async.
}
return CompletableFuture.supplyAsync(() -> {
String identifier = serializeKey(key);
@@ -124,11 +99,12 @@ public abstract class UserDataManager<K, U extends UserData<K>> {
}
}, executor).thenApply((data) -> {
if (cacheCondition.get()) dataCache.put(key, data);
if (cacheCondition.get() && !data.isDropping()) dataCache.put(key, data);
return data;
});
}
@Override
public @NotNull CompletableFuture<Boolean> save(@NotNull U user) {
return CompletableFuture.supplyAsync(() -> {
String identifier = serializeKey(user.getKey());
@@ -148,17 +124,18 @@ public abstract class UserDataManager<K, U extends UserData<K>> {
}, executor);
}
public @NotNull CompletableFuture<Boolean> unload(@NotNull K key) {
return unload(key, true);
}
@Override
public @NotNull CompletableFuture<Boolean> unload(@NotNull K key, boolean save) {
U data = getNullable(key);
if (data == null) return CompletableFuture.completedFuture(false);
data.setDropping(true); // Mark the data as unloading.
if (save) {
return save(data).thenApply(result -> {
// Check if the data is still unloading,
// which cloud be interrupted by the next load.
if (data.isDropping()) {
this.dataCache.remove(key);
}
return result;
});
} else {
@@ -168,6 +145,7 @@ public abstract class UserDataManager<K, U extends UserData<K>> {
}
@Override
public @NotNull CompletableFuture<Boolean> modify(@NotNull K key, @NotNull Consumer<U> consumer) {
U cached = getNullable(key);
if (cached != null) {
@@ -176,13 +154,14 @@ public abstract class UserDataManager<K, U extends UserData<K>> {
return true;
}, executor);
} else {
return load(key, false).thenApply((data) -> {
return load(key, true).thenApply((data) -> {
consumer.accept(data);
return data;
}).thenCompose(this::save);
}).thenCompose(data -> unload(key, true));
}
}
@Override
public <V> @NotNull CompletableFuture<V> peek(@NotNull K key, @NotNull Function<U, V> function) {
U cached = getNullable(key);
if (cached != null) {
@@ -192,10 +171,6 @@ public abstract class UserDataManager<K, U extends UserData<K>> {
}
}
public @NotNull CompletableFuture<Map<K, U>> loadOnline(@NotNull Function<Player, ? extends K> function) {
return loadGroup(Bukkit.getOnlinePlayers(), function, OfflinePlayer::isOnline);
}
public <T> @NotNull CompletableFuture<Map<K, U>> loadGroup(@NotNull Collection<? extends T> users,
@NotNull Function<? super T, ? extends K> function,
@NotNull Predicate<T> cacheCondition) {
@@ -218,15 +193,7 @@ public abstract class UserDataManager<K, U extends UserData<K>> {
return task.thenApply(Collections::unmodifiableMap);
}
public @NotNull CompletableFuture<Map<K, U>> loadGroup(@NotNull Collection<K> allKeys,
@NotNull Predicate<K> cacheCondition) {
return loadGroup(allKeys, Function.identity(), cacheCondition);
}
public @NotNull CompletableFuture<Map<K, U>> loadGroup(@NotNull Collection<K> allKeys) {
return loadGroup(allKeys, (v) -> false);
}
@Override
public void saveAll() {
if (getDataCache().isEmpty()) return;
for (U u : getDataCache().values()) {
@@ -239,6 +206,7 @@ public abstract class UserDataManager<K, U extends UserData<K>> {
}
}
@Override
public int unloadAll(boolean save) {
if (save) saveAll();
int size = getDataCache().size();
@@ -0,0 +1,95 @@
package cc.carm.lib.easyplugin.user;
import com.google.common.collect.ImmutableSet;
import org.bukkit.Bukkit;
import org.bukkit.OfflinePlayer;
import org.bukkit.entity.Player;
import org.jetbrains.annotations.NotNull;
import org.jetbrains.annotations.Nullable;
import org.jetbrains.annotations.Unmodifiable;
import java.util.Collection;
import java.util.Map;
import java.util.Optional;
import java.util.Set;
import java.util.concurrent.CompletableFuture;
import java.util.function.Consumer;
import java.util.function.Function;
import java.util.function.Predicate;
import java.util.function.Supplier;
import java.util.logging.Logger;
public interface UserDataRegistry<K, U extends UserData<K>> {
void shutdown();
@NotNull Logger getLogger();
@NotNull Map<K, U> cache();
default String serializeKey(@NotNull K key) {
return key.toString();
}
default @NotNull CompletableFuture<U> load(@NotNull K key) {
return load(key, false);
}
default @NotNull CompletableFuture<U> load(@NotNull K key, boolean cache) {
return load(key, () -> cache);
}
@Unmodifiable
default @NotNull Set<U> list() {
return ImmutableSet.copyOf(cache().values());
}
default @NotNull U get(@NotNull K key) {
return Optional.ofNullable(getNullable(key)).orElseThrow(() -> new NullPointerException("User " + key + " not found."));
}
default @Nullable U getNullable(@NotNull K key) {
return cache().get(key);
}
default @NotNull Optional<@Nullable U> getOptional(@NotNull K key) {
return Optional.ofNullable(getNullable(key));
}
@NotNull CompletableFuture<U> load(@NotNull K key, @NotNull Supplier<Boolean> cacheCondition);
@NotNull CompletableFuture<Boolean> save(@NotNull U user);
default @NotNull CompletableFuture<Boolean> unload(@NotNull K key) {
return unload(key, true);
}
@NotNull CompletableFuture<Boolean> unload(@NotNull K key, boolean save);
@NotNull CompletableFuture<Boolean> modify(@NotNull K key, @NotNull Consumer<U> consumer);
<V> @NotNull CompletableFuture<V> peek(@NotNull K key, @NotNull Function<U, V> function);
default @NotNull CompletableFuture<Map<K, U>> loadOnline(@NotNull Function<Player, ? extends K> function) {
return loadGroup(Bukkit.getOnlinePlayers(), function, OfflinePlayer::isOnline);
}
<T> @NotNull CompletableFuture<Map<K, U>> loadGroup(@NotNull Collection<? extends T> users,
@NotNull Function<? super T, ? extends K> function,
@NotNull Predicate<T> cacheCondition);
default @NotNull CompletableFuture<Map<K, U>> loadGroup(@NotNull Collection<K> allKeys,
@NotNull Predicate<K> cacheCondition) {
return loadGroup(allKeys, Function.identity(), cacheCondition);
}
default @NotNull CompletableFuture<Map<K, U>> loadGroup(@NotNull Collection<K> allKeys) {
return loadGroup(allKeys, (v) -> false);
}
void saveAll();
int unloadAll(boolean save);
}
+1 -1
View File
@@ -5,7 +5,7 @@
<parent>
<artifactId>easyplugin-parent</artifactId>
<groupId>cc.carm.lib</groupId>
<version>1.5.12</version>
<version>1.5.13</version>
<relativePath>../../pom.xml</relativePath>
</parent>
<modelVersion>4.0.0</modelVersion>
+1 -1
View File
@@ -5,7 +5,7 @@
<parent>
<artifactId>easyplugin-parent</artifactId>
<groupId>cc.carm.lib</groupId>
<version>1.5.12</version>
<version>1.5.13</version>
<relativePath>../../pom.xml</relativePath>
</parent>
<modelVersion>4.0.0</modelVersion>
+1 -1
View File
@@ -5,7 +5,7 @@
<parent>
<artifactId>easyplugin-parent</artifactId>
<groupId>cc.carm.lib</groupId>
<version>1.5.12</version>
<version>1.5.13</version>
<relativePath>../../pom.xml</relativePath>
</parent>
<modelVersion>4.0.0</modelVersion>
+1 -1
View File
@@ -5,7 +5,7 @@
<parent>
<artifactId>easyplugin-parent</artifactId>
<groupId>cc.carm.lib</groupId>
<version>1.5.12</version>
<version>1.5.13</version>
<relativePath>../../pom.xml</relativePath>
</parent>
<modelVersion>4.0.0</modelVersion>
+1 -1
View File
@@ -5,7 +5,7 @@
<parent>
<artifactId>easyplugin-parent</artifactId>
<groupId>cc.carm.lib</groupId>
<version>1.5.12</version>
<version>1.5.13</version>
<relativePath>../../pom.xml</relativePath>
</parent>
<modelVersion>4.0.0</modelVersion>
+1 -1
View File
@@ -5,7 +5,7 @@
<parent>
<artifactId>easyplugin-parent</artifactId>
<groupId>cc.carm.lib</groupId>
<version>1.5.12</version>
<version>1.5.13</version>
<relativePath>../../pom.xml</relativePath>
</parent>
<modelVersion>4.0.0</modelVersion>
+1 -1
View File
@@ -5,7 +5,7 @@
<parent>
<artifactId>easyplugin-parent</artifactId>
<groupId>cc.carm.lib</groupId>
<version>1.5.12</version>
<version>1.5.13</version>
<relativePath>../../pom.xml</relativePath>
</parent>
<modelVersion>4.0.0</modelVersion>
+30 -23
View File
@@ -15,7 +15,7 @@
<groupId>cc.carm.lib</groupId>
<artifactId>easyplugin-parent</artifactId>
<packaging>pom</packaging>
<version>1.5.12</version>
<version>1.5.13</version>
<modules>
<module>base/color</module>
<module>base/utils</module>
@@ -124,7 +124,7 @@
<dependency>
<groupId>org.jetbrains</groupId>
<artifactId>annotations</artifactId>
<version>23.0.0</version>
<version>26.0.2</version>
<scope>provided</scope>
</dependency>
@@ -142,12 +142,12 @@
<dependency>
<groupId>me.clip</groupId>
<artifactId>placeholderapi</artifactId>
<version>2.10.9</version>
<version>2.11.6</version>
</dependency>
<dependency>
<groupId>com.github.MilkBowl</groupId>
<artifactId>VaultAPI</artifactId>
<version>1.7</version>
<version>1.7.1</version>
</dependency>
<dependency>
<groupId>cc.carm.lib</groupId>
@@ -162,7 +162,7 @@
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-surefire-plugin</artifactId>
<version>2.22.1</version>
<version>3.5.2</version>
<configuration>
<useSystemClassLoader>false</useSystemClassLoader>
</configuration>
@@ -170,7 +170,7 @@
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-compiler-plugin</artifactId>
<version>3.8.1</version>
<version>3.14.0</version>
<configuration>
<source>${project.jdk.version}</source>
<target>${project.jdk.version}</target>
@@ -181,12 +181,12 @@
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-jar-plugin</artifactId>
<version>3.2.0</version>
<version>3.4.2</version>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-source-plugin</artifactId>
<version>3.2.0</version>
<version>3.3.1</version>
<executions>
<execution>
<phase>package</phase>
@@ -203,7 +203,7 @@
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-gpg-plugin</artifactId>
<version>3.0.1</version>
<version>3.2.7</version>
<executions>
<execution>
<id>sign-artifacts</id>
@@ -223,7 +223,7 @@
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-release-plugin</artifactId>
<version>2.5.3</version>
<version>3.1.1</version>
<configuration>
<autoVersionSubmodules>true</autoVersionSubmodules>
<useReleaseProfile>false</useReleaseProfile>
@@ -237,7 +237,7 @@
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-javadoc-plugin</artifactId>
<version>3.2.0</version>
<version>3.11.2</version>
<configuration>
<classifier>javadoc</classifier>
<detectJavaApiLink>false</detectJavaApiLink>
@@ -258,7 +258,7 @@
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-shade-plugin</artifactId>
<version>3.2.3</version>
<version>3.6.0</version>
<executions>
<execution>
<phase>package</phase>
@@ -296,17 +296,24 @@
<profiles>
<profile>
<id>ossrh</id>
<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>
<id>central</id>
<build>
<plugins>
<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>
<excludeArtifacts>
<excludeArtifact>configured-demo</excludeArtifact>
</excludeArtifacts>
</configuration>
</plugin>
</plugins>
</build>
</profile>
<profile>
+6
View File
@@ -0,0 +1,6 @@
{
"$schema": "https://docs.renovatebot.com/renovate-schema.json",
"extends": [
"config:recommended"
]
}