From aea4520277e9c9665caf9af9b55fc0f151e99231 Mon Sep 17 00:00:00 2001 From: William278 Date: Fri, 24 Feb 2023 11:26:29 +0000 Subject: [PATCH] Fix same version reporting as out-of-date --- .github/workflows/gradle-ci.yml | 4 +- .idea/gradle.xml | 4 +- .idea/workspace.xml | 79 +++++++------------ build.gradle | 3 +- .../william278/desertwell/UpdateChecker.java | 2 +- 5 files changed, 36 insertions(+), 56 deletions(-) diff --git a/.github/workflows/gradle-ci.yml b/.github/workflows/gradle-ci.yml index 3c2ddae..b8ab462 100644 --- a/.github/workflows/gradle-ci.yml +++ b/.github/workflows/gradle-ci.yml @@ -18,9 +18,7 @@ permissions: jobs: build: - runs-on: ubuntu-latest - steps: - uses: actions/checkout@v3 - name: Set up JDK 11 @@ -31,4 +29,4 @@ jobs: - name: Build with Gradle uses: gradle/gradle-build-action@67421db6bd0bf253fb4bd25b31ebb98943c375e1 with: - arguments: test + arguments: test \ No newline at end of file diff --git a/.idea/gradle.xml b/.idea/gradle.xml index 59c272e..10e7646 100644 --- a/.idea/gradle.xml +++ b/.idea/gradle.xml @@ -4,9 +4,11 @@ - + + - + - { - "keyToString": { - "RunOnceActivity.OpenProjectViewOnStart": "true", - "RunOnceActivity.ShowReadmeOnStart": "true", - "SHARE_PROJECT_CONFIGURATION_FILES": "true", - "WebServerToolWindowFactoryState": "false", - "last_opened_file_path": "C:/Users/William/IdeaProjects/DesertWell/src/main/java/net/william278/desertwell", - "nodejs_package_manager_path": "npm" + +}]]> @@ -67,8 +74,8 @@ - - + + - - false - true - false - - - - - - - false + true true false - + - - - + + - - - + @@ -160,6 +137,7 @@ 1661334712505 + 1661342956453 @@ -195,6 +173,7 @@ - \ No newline at end of file diff --git a/build.gradle b/build.gradle index f165196..ae0e23d 100644 --- a/build.gradle +++ b/build.gradle @@ -1,10 +1,11 @@ plugins { id 'java' id 'maven-publish' + id 'com.github.johnrengelman.shadow' version '6.1.0' } group 'net.william278' -version '1.1' +version '1.1.1' repositories { mavenCentral() diff --git a/src/main/java/net/william278/desertwell/UpdateChecker.java b/src/main/java/net/william278/desertwell/UpdateChecker.java index deb429d..8d49c7a 100644 --- a/src/main/java/net/william278/desertwell/UpdateChecker.java +++ b/src/main/java/net/william278/desertwell/UpdateChecker.java @@ -74,7 +74,7 @@ public class UpdateChecker { * @return A {@link CompletableFuture} containing true if the current plugin {@link Version} is outdated */ public CompletableFuture isUpToDate() { - return getLatestVersion().thenApply(latestVersion -> currentVersion.compareTo(latestVersion) > 0); + return getLatestVersion().thenApply(latestVersion -> currentVersion.compareTo(latestVersion) >= 0); } } \ No newline at end of file