From 7d11434c32f2c52046e37e1f7c38317138610cbc Mon Sep 17 00:00:00 2001 From: "Gabriele C." Date: Sun, 2 Aug 2015 02:47:16 +0200 Subject: [PATCH 1/7] Update pom.xml --- pom.xml | 40 +++++++++++++++++++++++++++++----------- 1 file changed, 29 insertions(+), 11 deletions(-) diff --git a/pom.xml b/pom.xml index 56f244215..3a4b7c1a0 100644 --- a/pom.xml +++ b/pom.xml @@ -11,18 +11,16 @@ AuthMeReloaded Authentication plugin for CraftBukkit/Spigot! + 2013 http://dev.bukkit.org/bukkit-plugins/authme-reloaded/ + - - UTF-8 - - - 1.7 - 1.7 - - - 1.8.8-R0.1-SNAPSHOT - + + scm:git:https://github.com/Xephi/AuthMeReloaded.git + scm:git:git@github.com:Xephi/AuthMeReloaded.git + http://github.com/Xephi/AuthMeReloaded + HEAD + @@ -35,6 +33,26 @@ https://github.com/Xephi/AuthMeReloaded/issues + + + Apache-2.0 + http://www.apache.org/licenses/LICENSE-2.0 + + + + + UTF-8 + + + 1.7 + 1.7 + + + 1.8.8-R0.1-SNAPSHOT + + AuthMe + + @@ -75,7 +93,7 @@ ${manifest.file} - AuthMe-${project.version} + ${jarPluginName}-${project.version} From acbae36ddf5a961ffcaaddb112db3ce9945dd8cd Mon Sep 17 00:00:00 2001 From: Gabriele C Date: Sun, 2 Aug 2015 14:22:34 +0200 Subject: [PATCH 2/7] Spaces in pom + optimizations --- pom.xml | 1114 ++++++++--------- src/main/java/fr/xephi/authme/AuthMe.java | 1 + .../xephi/authme/cache/backup/FileCache.java | 6 +- .../xephi/authme/commands/AdminCommand.java | 3 + 4 files changed, 542 insertions(+), 582 deletions(-) diff --git a/pom.xml b/pom.xml index 3a4b7c1a0..575582411 100644 --- a/pom.xml +++ b/pom.xml @@ -1,623 +1,575 @@ - 4.0.0 + xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"> + 4.0.0 - fr.xephi - authme - 5.0-SNAPSHOT + fr.xephi + authme + 5.0-SNAPSHOT - jar + AuthMeReloaded + Authentication plugin for CraftBukkit/Spigot! + 2013 + http://dev.bukkit.org/bukkit-plugins/authme-reloaded/ + - AuthMeReloaded - Authentication plugin for CraftBukkit/Spigot! - 2013 - http://dev.bukkit.org/bukkit-plugins/authme-reloaded/ - + + scm:git:https://github.com/Xephi/AuthMeReloaded.git + scm:git:git@github.com:Xephi/AuthMeReloaded.git + http://github.com/Xephi/AuthMeReloaded + - - scm:git:https://github.com/Xephi/AuthMeReloaded.git - scm:git:git@github.com:Xephi/AuthMeReloaded.git - http://github.com/Xephi/AuthMeReloaded - HEAD - + + + jenkins + http://ci.xephi.fr/job/AuthMeReloaded/ + - - - jenkins - http://ci.xephi.fr/job/AuthMeReloaded/ - + + GitHub + https://github.com/Xephi/AuthMeReloaded/issues + - - GitHub - https://github.com/Xephi/AuthMeReloaded/issues - + + + Apache-2.0 + http://www.apache.org/licenses/LICENSE-2.0 + + - - - Apache-2.0 - http://www.apache.org/licenses/LICENSE-2.0 - - + + UTF-8 + + 1.7 + + 1.8.8-R0.1-SNAPSHOT + - - UTF-8 + + ${project.name}-${project.version} + + + . + true + ${basedir}/src/main/resources/ + + *.yml + + + + + + org.apache.maven.plugins + maven-compiler-plugin + 3.3 + + 1.7 + ${javaVersion} + + + + org.apache.maven.plugins + maven-shade-plugin + 2.4.1 + + + + com.maxmind.geoip:* + javax.mail:* + com.sun.mail:* + com.comphenix.attribute:* + org.mcstats.*:* + com.zaxxer:* + org.slf4j:* + + + + + org.mcstats + fr.xephi.authme + + + + + + package + + shade + + + + + + - - 1.7 - 1.7 + - - 1.8.8-R0.1-SNAPSHOT - - AuthMe - + + + spigot-repo + https://hub.spigotmc.org/nexus/content/groups/public + - - - - org.apache.maven.plugins - maven-compiler-plugin - 3.3 - - ${maven.compiler.source} - ${maven.compiler.target} - - - - com.google.code.maven-replacer-plugin - replacer - 1.5.3 - - - prepare-package - - replace - - - - - target/classes/plugin.yml - - - maven-version - ${project.version} - - - - - - maven-jar-plugin - 2.6 - - - ${manifest.file} - - ${jarPluginName}-${project.version} - - - - org.apache.maven.plugins - maven-shade-plugin - 2.4.1 - - - - com.maxmind.geoip:* - javax.mail:* - com.sun.mail:* - com.comphenix.attribute:* - org.mcstats.*:* - com.zaxxer:* - org.slf4j:* - - - - - org.mcstats - fr.xephi.authme - - - - - - package - - shade - - - - - - com.versioneye - versioneye-maven-plugin - 3.5.1 - - 55bab9e8653762002000190a - - - - - + + + ess-repo + http://repo.ess3.net/content/groups/public + - + + + citizensapi-repo + http://ci.citizensnpcs.co/plugin/repository/project/CitizensAPI/LastSuccessful/repository + - - - spigot-repo - https://hub.spigotmc.org/nexus/content/groups/public - + + + minelink-thirdparty + http://repo.minelink.net/content/repositories/public + - - - ess-repo - http://repo.ess3.net/content/groups/public - + + + comphenix-snapshots + http://repo.comphenix.net/content/repositories/public + - - - citizensapi-repo - http://ci.citizensnpcs.co/plugin/repository/project/CitizensAPI/LastSuccessful/repository - + + + onarandombox + http://repo.onarandombox.com/content/groups/public + - - - minelink-thirdparty - http://repo.minelink.net/content/repositories/public - + + + vault-repo + http://nexus.theyeticave.net/content/repositories/pub_releases + - - - comphenix-snapshots - http://repo.comphenix.net/content/repositories/public - + + + luricos-releases + http://repo.luricos.de/content/repositories/releases + - - - onarandombox - http://repo.onarandombox.com/content/groups/public - + + + xephi-repo + http://ci.xephi.fr/plugin/repository/everything/ + - - - vault-repo - http://nexus.theyeticave.net/content/repositories/pub_releases - + + + mcstats-snapshots + http://repo.mcstats.org/content/repositories/snapshots/ + - - - luricos-releases - http://repo.luricos.de/content/repositories/releases - + - - - xephi-repo - http://ci.xephi.fr/plugin/repository/everything/ - + - - - mcstats-snapshots - http://repo.mcstats.org/content/repositories/snapshots/ - + - + + + org.slf4j + slf4j-simple + 1.7.12 + compile + + + com.zaxxer + HikariCP + 2.4.0 + compile + + + org.slf4j + slf4j-api + + + org.slf4j + slf4j-simple + + + - + + + org.xerial + sqlite-jdbc + 3.8.11 + compile + - - - - - org.slf4j - slf4j-simple - 1.7.12 - compile - - - com.zaxxer - HikariCP - 2.4.0 - compile - - - org.slf4j - slf4j-api - - - org.slf4j - slf4j-simple - - - - - - - org.xerial - sqlite-jdbc - 3.8.11 - compile - - - - - com.sun.mail - javax.mail - 1.5.4 - compile - + + + com.sun.mail + javax.mail + 1.5.4 + compile + - - - com.maxmind.geoip - geoip-api - 1.2.15 - compile - + + + com.maxmind.geoip + geoip-api + 1.2.15 + compile + - - - org.mcstats.bukkit - metrics - R8-SNAPSHOT - compile - - - org.bukkit - bukkit - - - org.bukkit - craftbukkit - - - + + + org.mcstats.bukkit + metrics + R8-SNAPSHOT + compile + + + org.bukkit + bukkit + + + - - - org.spigotmc - spigot-api - ${bukkitVersion} - provided - - - bungeecord-chat - net.md-5 - - - + + + org.bukkit + bukkit + ${bukkitVersion} + provided + - - - com.comphenix.attribute - AttributeStorage - 0.0.2-SNAPSHOT - compile - - - org.bukkit - bukkit - - - org.bukkit - craftbukkit - - - + + + com.comphenix.attribute + AttributeStorage + 0.0.2-SNAPSHOT + compile + + + org.bukkit + bukkit + + + org.bukkit + craftbukkit + + + - - - net.milkbowl.vault - VaultAPI - 1.5 - provided - - - org.bukkit - bukkit - - - org.bukkit - craftbukkit - - - + + + net.milkbowl.vault + VaultAPI + 1.5 + provided + + + org.bukkit + bukkit + + + org.bukkit + craftbukkit + + + - - - net.citizensnpcs - citizensapi - 2.0.16-SNAPSHOT - provided - - - org.bukkit - bukkit - - - org.bukkit - craftbukkit - - - + + + net.citizensnpcs + citizensapi + 2.0.16-SNAPSHOT + provided + + + org.bukkit + bukkit + + + org.bukkit + craftbukkit + + + - - - com.onarandombox.multiversecore - Multiverse-Core - 2.5 - jar - provided - - - org.bukkit - bukkit - - - org.bukkit - craftbukkit - - - AllPay - com.fernferret.allpay - - - Vault - net.milkbowl.vault - - - CommandHandler - com.pneumaticraft.commandhandler - - - + + + com.onarandombox.multiversecore + Multiverse-Core + 2.5 + jar + provided + + + org.bukkit + bukkit + + + org.bukkit + craftbukkit + + + AllPay + com.fernferret.allpay + + + Vault + net.milkbowl.vault + + + CommandHandler + com.pneumaticraft.commandhandler + + + - - - net.ess3 - Essentials - 2.14-SNAPSHOT - provided - - - org.bukkit - bukkit - - - org.bukkit - craftbukkit - - - + + + net.ess3 + Essentials + 2.14-SNAPSHOT + provided + + + org.bukkit + bukkit + + + org.bukkit + craftbukkit + + + - - - net.minelink - CombatTagPlus - 1.2.1-SNAPSHOT - provided - - - org.bukkit - bukkit - - - org.bukkit - craftbukkit - - - CombatTagPlusHook - net.minelink - - - CombatTagPlusFactions-v1_6 - net.minelink - - - CombatTagPlusCompat-v1_7_R3 - net.minelink - - - CombatTagPlusFactions-v1_8 - net.minelink - - - CombatTagPlusCompat-v1_7_R4 - net.minelink - - - CombatTagPlusWG-v5 - net.minelink - - - CombatTagPlusWG-v6 - net.minelink - - - CombatTagPlusCompat-API - net.minelink - - - CombatTagPlusFactions-v2_6 - net.minelink - - - CombatTagPlusCompat-v1_8_R3 - net.minelink - - - CombatTagPlusFactions-v2_7 - net.minelink - - - CombatTagPlusCompat-v1_8_R2 - net.minelink - - - CombatTagPlusCompat-v1_8_R1 - net.minelink - - - metrics-lite - org.mcstats.bukkit - - - + + + net.minelink + CombatTagPlus + 1.2.1-SNAPSHOT + provided + + + org.bukkit + bukkit + + + org.bukkit + craftbukkit + + + CombatTagPlusHook + net.minelink + + + CombatTagPlusFactions-v1_6 + net.minelink + + + CombatTagPlusCompat-v1_7_R3 + net.minelink + + + CombatTagPlusFactions-v1_8 + net.minelink + + + CombatTagPlusCompat-v1_7_R4 + net.minelink + + + CombatTagPlusWG-v5 + net.minelink + + + CombatTagPlusWG-v6 + net.minelink + + + CombatTagPlusCompat-API + net.minelink + + + CombatTagPlusFactions-v2_6 + net.minelink + + + CombatTagPlusCompat-v1_8_R3 + net.minelink + + + CombatTagPlusFactions-v2_7 + net.minelink + + + CombatTagPlusCompat-v1_8_R2 + net.minelink + + + CombatTagPlusCompat-v1_8_R1 + net.minelink + + + metrics-lite + org.mcstats.bukkit + + + - - - com.trc202 - CombatTag - 6.2.1-SNAPSHOT - provided - - - org.bukkit - bukkit - - - org.bukkit - craftbukkit - - - + + + com.trc202 + CombatTag + 6.2.1-SNAPSHOT + provided + + + org.bukkit + bukkit + + + org.bukkit + craftbukkit + + + - - - de.luricos.bukkit - xAuth - 2.6 - provided - - - org.bukkit - bukkit - - - org.bukkit - craftbukkit - - - updater - net.gravitydevelopment.updater - - - lombok - org.projectlombok - - - EssentialsGroupManager - net.ess3 - - - PermissionsEx - ru.tehkode - - - AccountsClient - com.mojang - - - + + + de.luricos.bukkit + xAuth + 2.6 + provided + + + org.bukkit + bukkit + + + org.bukkit + craftbukkit + + + updater + net.gravitydevelopment.updater + + + lombok + org.projectlombok + + + EssentialsGroupManager + net.ess3 + + + PermissionsEx + ru.tehkode + + + AccountsClient + com.mojang + + + - - - com.acrobot.chestshop - chestshop - 3.8.12 - provided - - - org.bukkit - bukkit - - - org.bukkit - craftbukkit - - - Vault - net.milkbowl.vault - - - odditem - info.somethingodd - - - scrollingmenusign - me.desht - - - truezip - de.schlichtherle - - - residence - net.t00thpick1 - - - Heroes - com.herocraftonline.heroes - - - HeroChat - com.dthielke.herochat - - - worldguard - com.sk89q - - - worldedit - com.sk89q - - - lwc - com.griefcraft.lwc - - - js - rhino - - - jchronic - com.sk89q - - - deadbolt - com.daemitus.deadbolt - - - bukkit-classloader-check - com.sk89q.spigot - - - jsr305 - com.google.code.findbugs - - - opencsv - net.sf.opencsv - - - simplechestlock - - com.webkonsept.bukkit.simplechestlock - - - - commandbook - com.sk89q - - - lockette - org.yi.acru.bukkit.lockette - - - + + + com.acrobot.chestshop + chestshop + 3.8.12 + provided + + + org.bukkit + bukkit + + + org.bukkit + craftbukkit + + + Vault + net.milkbowl.vault + + + odditem + info.somethingodd + + + scrollingmenusign + me.desht + + + truezip + de.schlichtherle + + + residence + net.t00thpick1 + + + Heroes + com.herocraftonline.heroes + + + HeroChat + com.dthielke.herochat + + + worldguard + com.sk89q + + + worldedit + com.sk89q + + + lwc + com.griefcraft.lwc + + + js + rhino + + + jchronic + com.sk89q + + + deadbolt + com.daemitus.deadbolt + + + bukkit-classloader-check + com.sk89q.spigot + + + jsr305 + com.google.code.findbugs + + + opencsv + net.sf.opencsv + + + simplechestlock + + com.webkonsept.bukkit.simplechestlock + + + + commandbook + com.sk89q + + + lockette + org.yi.acru.bukkit.lockette + + + - + diff --git a/src/main/java/fr/xephi/authme/AuthMe.java b/src/main/java/fr/xephi/authme/AuthMe.java index 7ed3dd9f4..9cf420a72 100644 --- a/src/main/java/fr/xephi/authme/AuthMe.java +++ b/src/main/java/fr/xephi/authme/AuthMe.java @@ -120,6 +120,7 @@ public class AuthMe extends JavaPlugin { this.database = database; } + @SuppressWarnings("deprecation") @Override public void onEnable() { authme = this; diff --git a/src/main/java/fr/xephi/authme/cache/backup/FileCache.java b/src/main/java/fr/xephi/authme/cache/backup/FileCache.java index 6c4e4be76..2a4b09eb6 100644 --- a/src/main/java/fr/xephi/authme/cache/backup/FileCache.java +++ b/src/main/java/fr/xephi/authme/cache/backup/FileCache.java @@ -504,7 +504,8 @@ public class FileCache { armours[i] = attributes.getStack(); else armours[i] = item; } - + } catch (final RuntimeException e) { + ConsoleLogger.showError("Error while reading file for " + player.getName() + ", some wipe inventory incoming..."); } catch (final Exception e) { ConsoleLogger.showError("Error while reading file for " + player.getName() + ", some wipe inventory incoming..."); } finally { @@ -513,6 +514,9 @@ public class FileCache { } return new DataFileCache(inv, armours, group, op, flying); } + } catch (RuntimeException e) { + ConsoleLogger.showError("Error while reading file for " + player.getName() + ", some wipe inventory incoming..."); + return null; } catch (Exception e) { ConsoleLogger.showError("Error while reading file for " + player.getName() + ", some wipe inventory incoming..."); return null; diff --git a/src/main/java/fr/xephi/authme/commands/AdminCommand.java b/src/main/java/fr/xephi/authme/commands/AdminCommand.java index 10a4e950e..7ee7e42ca 100644 --- a/src/main/java/fr/xephi/authme/commands/AdminCommand.java +++ b/src/main/java/fr/xephi/authme/commands/AdminCommand.java @@ -477,6 +477,7 @@ public class AdminCommand implements CommandExecutor { m.send(sender, "error"); return true; } + @SuppressWarnings("deprecation") Player target = Bukkit.getPlayer(name); PlayerCache.getInstance().removePlayer(name); Utils.getInstance().setGroup(name, groupType.UNREGISTERED); @@ -559,6 +560,7 @@ public class AdminCommand implements CommandExecutor { sender.sendMessage("Usage: /authme getip "); return true; } + @SuppressWarnings("deprecation") Player player = Bukkit.getPlayer(args[1]); if (player == null) { sender.sendMessage("This player is not actually online"); @@ -574,6 +576,7 @@ public class AdminCommand implements CommandExecutor { return true; } try { + @SuppressWarnings("deprecation") Player player = Bukkit.getPlayer(args[1]); if (player == null || !player.isOnline()) { sender.sendMessage("Player needs to be online!"); From 63e35e455061c081c3f3bcd9ab2b6ac880262e69 Mon Sep 17 00:00:00 2001 From: Gabriele C Date: Sun, 2 Aug 2015 14:36:03 +0200 Subject: [PATCH 3/7] Fix wrong jar name --- pom.xml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pom.xml b/pom.xml index 575582411..725af37c1 100644 --- a/pom.xml +++ b/pom.xml @@ -46,7 +46,7 @@ - ${project.name}-${project.version} + AuthMe-${project.version} . From 7d5fc908b5fa106b3c333f42536f15f1b4f100a3 Mon Sep 17 00:00:00 2001 From: Gabriele C Date: Sun, 2 Aug 2015 14:45:56 +0200 Subject: [PATCH 4/7] Use EssentialsX instead of Essentials --- pom.xml | 16 ++++++---------- 1 file changed, 6 insertions(+), 10 deletions(-) diff --git a/pom.xml b/pom.xml index 725af37c1..83f8bdda0 100644 --- a/pom.xml +++ b/pom.xml @@ -110,10 +110,10 @@ https://hub.spigotmc.org/nexus/content/groups/public - + ess-repo - http://repo.ess3.net/content/groups/public + https://ci.drtshock.net/plugin/repository/everything @@ -330,17 +330,13 @@ net.ess3 - Essentials - 2.14-SNAPSHOT + EssentialsX + 2.0.1-SNAPSHOT provided - org.bukkit - bukkit - - - org.bukkit - craftbukkit + org.spigotmc + spigot-api From fc97c605290d4329fb7fbff8d1dc92ad1ccde8d9 Mon Sep 17 00:00:00 2001 From: "Gabriele C." Date: Mon, 3 Aug 2015 19:18:30 +0200 Subject: [PATCH 5/7] Update plugin.yml --- src/main/resources/plugin.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/main/resources/plugin.yml b/src/main/resources/plugin.yml index b52d57942..68aab3b36 100644 --- a/src/main/resources/plugin.yml +++ b/src/main/resources/plugin.yml @@ -3,7 +3,7 @@ author: Xephi59 website: http://dev.bukkit.org/bukkit-plugins/authme-reloaded/ description: AuthMe prevents people, which aren't logged in, from doing stuff like placing blocks, moving, typing commands or seeing the inventory of the player. main: fr.xephi.authme.AuthMe -version: maven-version +version: ${project.version} softdepend: [Vault, ChestShop, Multiverse-Core, Citizens, CombatTag, Essentials, EssentialsSpawn] commands: register: From 52b48f71c4e18462580a013026b065825c046593 Mon Sep 17 00:00:00 2001 From: "Gabriele C." Date: Tue, 4 Aug 2015 15:16:59 +0200 Subject: [PATCH 6/7] Update AuthMe.java --- src/main/java/fr/xephi/authme/AuthMe.java | 1 - 1 file changed, 1 deletion(-) diff --git a/src/main/java/fr/xephi/authme/AuthMe.java b/src/main/java/fr/xephi/authme/AuthMe.java index 9cf420a72..7ed3dd9f4 100644 --- a/src/main/java/fr/xephi/authme/AuthMe.java +++ b/src/main/java/fr/xephi/authme/AuthMe.java @@ -120,7 +120,6 @@ public class AuthMe extends JavaPlugin { this.database = database; } - @SuppressWarnings("deprecation") @Override public void onEnable() { authme = this; From 20c75f19803b8669189449c4c26c61c8be137f21 Mon Sep 17 00:00:00 2001 From: "Gabriele C." Date: Tue, 4 Aug 2015 15:18:45 +0200 Subject: [PATCH 7/7] Update AdminCommand.java --- src/main/java/fr/xephi/authme/commands/AdminCommand.java | 3 --- 1 file changed, 3 deletions(-) diff --git a/src/main/java/fr/xephi/authme/commands/AdminCommand.java b/src/main/java/fr/xephi/authme/commands/AdminCommand.java index d55df865a..52fbec31e 100644 --- a/src/main/java/fr/xephi/authme/commands/AdminCommand.java +++ b/src/main/java/fr/xephi/authme/commands/AdminCommand.java @@ -477,7 +477,6 @@ public class AdminCommand implements CommandExecutor { m.send(sender, "error"); return true; } - @SuppressWarnings("deprecation") Player target = Bukkit.getPlayer(name); PlayerCache.getInstance().removePlayer(name); Utils.getInstance().setGroup(name, groupType.UNREGISTERED); @@ -560,7 +559,6 @@ public class AdminCommand implements CommandExecutor { sender.sendMessage("Usage: /authme getip "); return true; } - @SuppressWarnings("deprecation") Player player = Bukkit.getPlayer(args[1]); if (player == null) { sender.sendMessage("This player is not actually online"); @@ -576,7 +574,6 @@ public class AdminCommand implements CommandExecutor { return true; } try { - @SuppressWarnings("deprecation") Player player = Bukkit.getPlayer(args[1]); if (player == null || !player.isOnline()) { sender.sendMessage("Player needs to be online!");