Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/workflows/build-pr.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,6 @@ jobs:
uses: actions/setup-java@v5
with:
distribution: temurin
java-version: 21
java-version: 25
- name: Build on ${{ matrix.os }}
run: ./gradlew clean build
2 changes: 1 addition & 1 deletion .github/workflows/main-build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,6 @@ jobs:
uses: actions/setup-java@v5
with:
distribution: temurin
java-version: 21
java-version: 25
- name: Build on ${{ matrix.os }}
run: ./gradlew test
20 changes: 5 additions & 15 deletions .github/workflows/publishing.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,34 +2,24 @@ name: Publish JAR

on:
push:
branches:
- main
- master
- develop
tags:
- '**'
jobs:
build:
runs-on: ubuntu-latest

env:
ONELITEFEATHER_MAVEN_USERNAME: ${{ secrets.ONELITEFEATHER_MAVEN_USERNAME }}
ONELITEFEATHER_MAVEN_PASSWORD: ${{ secrets.ONELITEFEATHER_MAVEN_PASSWORD }}
steps:
- name: Checkout repository
uses: actions/checkout@v5

- name: Set up JDK 21
- name: Set up JDK 25
uses: actions/setup-java@v5
with:
distribution: 'temurin'
java-version: '21'

java-version: '25'
- name: Build with Gradle
run: ./gradlew build
env:
ONELITEFEATHER_MAVEN_USERNAME: ${{ secrets.ONELITEFEATHER_MAVEN_USERNAME }}
ONELITEFEATHER_MAVEN_PASSWORD: ${{ secrets.ONELITEFEATHER_MAVEN_PASSWORD }}

- name: Publish to Maven
run: ./gradlew publish
env:
ONELITEFEATHER_MAVEN_USERNAME: ${{ secrets.ONELITEFEATHER_MAVEN_USERNAME }}
ONELITEFEATHER_MAVEN_PASSWORD: ${{ secrets.ONELITEFEATHER_MAVEN_PASSWORD }}
7 changes: 3 additions & 4 deletions build.gradle.kts
Original file line number Diff line number Diff line change
@@ -1,17 +1,16 @@
plugins {
java
`java-library`
`maven-publish`
jacoco
}

group = "net.theevilreaper"
version = "1.11.2"
version = "1.12.0"
description = "Aves"

java {
toolchain {
languageVersion = JavaLanguageVersion.of(21)
languageVersion = JavaLanguageVersion.of(25)
}
withJavadocJar()
withSourcesJar()
Expand All @@ -38,7 +37,7 @@ dependencies {
tasks {
compileJava {
options.encoding = "UTF-8"
options.release.set(21)
options.release.set(25)
}

jacocoTestReport {
Expand Down
2 changes: 1 addition & 1 deletion settings.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ dependencyResolutionManagement {
}
versionCatalogs {
create("libs") {
version("bom", "1.4.5")
version("bom", "1.5.0")
library("mycelium.bom", "net.onelitefeather", "mycelium-bom").versionRef("bom")
library("minestom","net.minestom", "minestom").withoutVersion()
library("adventure", "net.kyori", "adventure-text-minimessage").withoutVersion()
Expand Down
4 changes: 2 additions & 2 deletions src/main/java/net/theevilreaper/aves/util/Futures.java
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
package net.theevilreaper.aves.util;

import it.unimi.dsi.fastutil.booleans.BooleanConsumer;
import org.jetbrains.annotations.NotNull;

import java.time.Duration;
import java.util.concurrent.CompletableFuture;
import java.util.concurrent.CountDownLatch;
import java.util.concurrent.TimeUnit;
import java.util.function.Consumer;

/**
* Taken from <a href="https://github.com/Minestom/Arena/blob/master/src/main/java/net/minestom/arena/utils/ConcurrentUtils.java">...</a>
Expand All @@ -33,7 +33,7 @@ private Futures() {
* </ul>
* @return the new CompletionStage
*/
public static CompletableFuture<Void> thenRunOrTimeout(@NotNull CompletableFuture<?> future, @NotNull Duration timeout, BooleanConsumer action) {
public static CompletableFuture<Void> thenRunOrTimeout(@NotNull CompletableFuture<?> future, @NotNull Duration timeout, Consumer<Boolean> action) {
final CompletableFuture<Boolean> f = new CompletableFuture<>();
CompletableFuture.delayedExecutor(timeout.toNanos(), TimeUnit.NANOSECONDS).execute(() -> f.complete(true));
future.thenRun(() -> f.complete(false));
Expand Down