Deploy only the universal jar to the target folder

This commit is contained in:
games647
2016-09-18 11:38:49 +02:00
parent a02acd2d63
commit bef90d11cd
6 changed files with 21 additions and 14 deletions

View File

@ -9,8 +9,8 @@ import com.github.games647.fastlogin.bukkit.hooks.UltraAuthHook;
import com.github.games647.fastlogin.bukkit.hooks.xAuthHook; import com.github.games647.fastlogin.bukkit.hooks.xAuthHook;
import com.github.games647.fastlogin.core.hooks.AuthPlugin; import com.github.games647.fastlogin.core.hooks.AuthPlugin;
import com.google.common.collect.Lists; import com.google.common.collect.Lists;
import java.util.List;
import java.util.List;
import java.util.logging.Level; import java.util.logging.Level;
import org.bukkit.Bukkit; import org.bukkit.Bukkit;
@ -40,6 +40,7 @@ public class DelayedAuthHook implements Runnable {
private boolean registerHooks() { private boolean registerHooks() {
AuthPlugin<Player> authPluginHook = null; AuthPlugin<Player> authPluginHook = null;
try { try {
@SuppressWarnings("unchecked")
List<Class<? extends AuthPlugin<Player>>> supportedHooks = Lists.newArrayList(AuthMeHook.class List<Class<? extends AuthPlugin<Player>>> supportedHooks = Lists.newArrayList(AuthMeHook.class
, CrazyLoginHook.class, LogItHook.class, LoginSecurityHook.class, UltraAuthHook.class , CrazyLoginHook.class, LogItHook.class, LoginSecurityHook.class, UltraAuthHook.class
, xAuthHook.class); , xAuthHook.class);

View File

@ -70,10 +70,17 @@ public class FastLoginBungee extends Plugin {
public void saveDefaultFile(String fileName) { public void saveDefaultFile(String fileName) {
File configFile = new File(getDataFolder(), fileName); File configFile = new File(getDataFolder(), fileName);
if (!configFile.exists()) { if (!configFile.exists()) {
try (InputStream in = getResourceAsStream(fileName)) { InputStream in = getResourceAsStream(fileName);
try {
Files.copy(in, configFile.toPath()); Files.copy(in, configFile.toPath());
} catch (IOException ioExc) { } catch (IOException ioExc) {
getLogger().log(Level.SEVERE, "Error saving default " + fileName, ioExc); getLogger().log(Level.SEVERE, "Error saving default " + fileName, ioExc);
} finally {
try {
in.close();
} catch (IOException ex) {
getLogger().log(Level.SEVERE, null, ex);
}
} }
} }
} }

View File

@ -8,7 +8,7 @@ main: ${project.groupId}.${project.artifactId}.${project.name}
version: ${project.version} version: ${project.version}
author: games647, http://github.com/games647/FastLogin/graphs/contributors author: games647, http://github.com/games647/FastLogin/graphs/contributors
softdepends: softdepend:
# BungeeCord auth plugins # BungeeCord auth plugins
- BungeeAuth - BungeeAuth

View File

@ -13,8 +13,7 @@ public class PlayerProfile {
private String lastIp; private String lastIp;
private long lastLogin; private long lastLogin;
public PlayerProfile(long userId, UUID uuid, String playerName, boolean premium public PlayerProfile(long userId, UUID uuid, String playerName, boolean premium, String lastIp, long lastLogin) {
, String lastIp, long lastLogin) {
this.userId = userId; this.userId = userId;
this.uuid = uuid; this.uuid = uuid;
this.playerName = playerName; this.playerName = playerName;

View File

@ -56,15 +56,6 @@
<showDeprecation>true</showDeprecation> <showDeprecation>true</showDeprecation>
</configuration> </configuration>
</plugin> </plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-jar-plugin</artifactId>
<version>3.0.2</version>
<configuration>
<outputDirectory>${outputDir}</outputDirectory>
</configuration>
</plugin>
</plugins> </plugins>
<resources> <resources>

View File

@ -43,6 +43,15 @@
</execution> </execution>
</executions> </executions>
</plugin> </plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-jar-plugin</artifactId>
<version>3.0.2</version>
<configuration>
<outputDirectory>${outputDir}</outputDirectory>
</configuration>
</plugin>
</plugins> </plugins>
</build> </build>