From e4f6c39bb7c3d75e6be865b3d7786861d05b255d Mon Sep 17 00:00:00 2001 From: Foorack Date: Sat, 7 Apr 2018 12:05:37 +0200 Subject: [PATCH 1/3] Fix Maven compiling --- pom.xml | 12 +++--------- 1 file changed, 3 insertions(+), 9 deletions(-) diff --git a/pom.xml b/pom.xml index 6aaff2ff9..a83198cda 100644 --- a/pom.xml +++ b/pom.xml @@ -12,7 +12,7 @@ jar PlotSquared-Bukkit-${project.version} - Bukkit/src/main/java + Bukkit/src true @@ -52,7 +52,7 @@ - Core/src/main/java + Core/src @@ -82,7 +82,7 @@ org.spigotmc spigot-api - 1.11-R0.1-SNAPSHOT + 1.12-R0.1-SNAPSHOT provided @@ -97,12 +97,6 @@ VaultAPI 1.5 provided - - - org.bukkit - bukkit - - From 90c3fac4fa0eae732ab6339add196aeb9cffaec1 Mon Sep 17 00:00:00 2001 From: Foorack Date: Sat, 7 Apr 2018 20:52:19 +0200 Subject: [PATCH 2/3] Fix PlotVersion when compiling with Maven --- .../intellectualcrafters/plot/PlotVersion.java | 17 +++++++++++++---- 1 file changed, 13 insertions(+), 4 deletions(-) diff --git a/Core/src/main/java/com/intellectualcrafters/plot/PlotVersion.java b/Core/src/main/java/com/intellectualcrafters/plot/PlotVersion.java index 24932ee88..d0c6e82fc 100644 --- a/Core/src/main/java/com/intellectualcrafters/plot/PlotVersion.java +++ b/Core/src/main/java/com/intellectualcrafters/plot/PlotVersion.java @@ -13,16 +13,25 @@ public class PlotVersion { this.year = Integer.parseInt(date[0]); this.month = Integer.parseInt(date[1]); this.day = Integer.parseInt(date[2]); - this.hash = Integer.parseInt(split[1], 16); - this.build = Integer.parseInt(split[2]); + if(split[1].equals("SNAPSHOT")) { // fallback when compiling with Maven + this.hash = 0; + this.build = 0; + } else { + this.hash = Integer.parseInt(split[1], 16); + this.build = Integer.parseInt(split[2]); + } } @Override public String toString() { - return "PlotSquared-" + year + "." + month + "." + day + "-" + Integer.toHexString(hash) + "-" + build; + if(hash == 0 && build == 0) { + return "PlotSquared-" + year + "." + month + "." + day + "-SNAPSHOT"; + } else { + return "PlotSquared-" + year + "." + month + "." + day + "-" + Integer.toHexString(hash) + "-" + build; + } } public boolean isNewer(PlotVersion other) { return other.build < this.build; } -} \ No newline at end of file +} From c5a30bd70886320cde46f2e2d3a09762ac39ec74 Mon Sep 17 00:00:00 2001 From: Foorack Date: Sat, 7 Apr 2018 20:52:31 +0200 Subject: [PATCH 3/3] Filter Core resources --- pom.xml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pom.xml b/pom.xml index a83198cda..e15400d8b 100644 --- a/pom.xml +++ b/pom.xml @@ -22,7 +22,7 @@ Bukkit/src/main/resources/ - false + true **/*.*